This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
geom_rug_alt <- function(mapping = NULL, | |
data = NULL, | |
stat = "identity", | |
position = "identity", | |
... | |
) | |
{ | |
GeomRugAlt$new(mapping = mapping, | |
data = data, | |
stat = stat, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TidyMultipleChoiceData <- function(file) { | |
multiple.choice.columns <- c("name", | |
"mc1", | |
"mc2", | |
"mc3", | |
"mc4", | |
"mc5", | |
"mc6", | |
"mc7", | |
"mc8" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
library(ggplot2) | |
set.seed(1001) | |
x <- rep(0, times = 1000) | |
x.jittered <- jitter(x, amount = 2) | |
y <- rnorm(1000) | |
dd <- data.frame(x, x.jittered, y) | |
p1 <- ggplot() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Check whether ggplot2 plots produce the same behavior | |
library(ggplot2) | |
qplot(hwy, cty, data = mpg, main = "Plot of City Mileage vs. Highway Mileage") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Making sure you have a fresh copy of granovaGG | |
remove.packages("granovaGG", lib = .libPaths()) | |
library(devtools) | |
install_github(repo = "granovaGG", username = "briandk", branch = "dev") | |
library(granovaGG) | |
library(granova) | |
# Creating a 7-inch by 7-inch test plot | |
setwd("~/Desktop/testplots") # I created the testplots directory in advance | |
granovagg.1w(data = mpg$hwy, group = mpg$manufacturer) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
detach(package:granovaGG) # this may throw an error | |
remove.packages("granovaGG", lib = .libPaths()) | |
### QUIT AND RESTART R.APP | |
library(devtools) | |
install_github(repo = "granovaGG", username = "briandk", branch = "dev") | |
library(granovaGG) | |
?granovagg.1w |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set.seed(1001) | |
library(granovaGG) | |
data(arousal) | |
# Red boxes for F < 1 | |
granovagg.1w(rnorm(100,10,2),rep(1:4,ea=25), main = "Random Data with F < 1") | |
# Blue boxes for F > 1 | |
granovagg.1w(chickwts$weight, group = chickwts$feed, main = "Chickwts Data with F > 1") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% This is how it should look | |
\eqn{LaTeX code goes here}{%ASCII fallback text goes here | |
} | |
% This is what it looks like after a parser forcibly applies a hard line break | |
\eqn{LaTeX code goes here}{%ASCII fallback | |
text goes here | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
void blank_string (char *s) { | |
int i = 0; | |
for (i = 0; i < 10; i = i + 1) { | |
*(s + i) = "5"; | |
} | |
*(s + 10) = "\0"; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int x; | |
int main (int argc, char const *argv[]) | |
{ | |
FILE *myFile = fopen("passenger.small.txt", "r"); | |
char myString[1000]; | |
int int1 = 0; | |
int int2 = 0; |
OlderNewer