Created
May 14, 2014 17:24
-
-
Save jvcasillas/f9a474f5b4a580470e8b to your computer and use it in GitHub Desktop.
ident_sigmoid
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
# Plot Spectrum Proportion | |
my_data$group <- factor(my_data$group, levels = c("EL", "NE", "LL")) | |
df<-with(my_data, aggregate(fpro, list(group=group, fstim=fstim), mean)) | |
df$se<-with(my_data, aggregate(fpro, list(group=group, fstim=fstim), function(x) sd(x)/sqrt(10)))[,3] | |
gp<-ggplot(df, aes(x=fstim, y=x, colour=group, ymin=x-se, ymax=x+se)) | |
gp +geom_line(aes(linetype=group), size = .4) + | |
geom_point(aes(shape=group)) + | |
geom_ribbon(alpha = 0.15, linetype=0) + | |
#geom_errorbar(aes(ymax=x+se, ymin=x-se)) + | |
ylim(0, 1) + | |
scale_x_continuous(breaks=seq(0, 10, by=1)) + | |
labs(list(title = "Sheep/ship spectrum continuum", | |
x = "Stimuli", y = "% Sheep")) + | |
theme_bw() + | |
theme(legend.position = c(0.95, 0.9)) + | |
theme(plot.title = element_text(size = rel(2))) + | |
theme(legend.text = element_text(size = 15)) + | |
theme(legend.title = element_text(size = 15)) + | |
theme(legend.background = element_rect(colour = 'grey50', | |
fill = 'grey97', size = .65, linetype='solid')) + | |
scale_linetype_discrete("Group") + | |
scale_shape_discrete("Group") + | |
scale_colour_discrete("Group") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment