# importing datasp <- read.csv("/Users/deborah/Desktop/hhelianthoides.csv") # the data#sp$headId = identification number assigned to flower head#sp$row = which row of styles (1=bottom row)#sp$treatment = pollination treatment applied#sp$styleDate = date when styles emerged#sp$dateTreat = date when treatment was first applied#sp$styleShriv = whether styles were shriveled on first visit after treatment (0=no, 1-yes)#sp$dateShriv = date when styles were observed to have shriveled#sp$daysPerstLong = large estimate of how long styles persisted#sp$daysPerstAvg = middle estimate of how long styles persisted#sp$daysPerstShort = small estimate of how long styles persisted#sp$lastDayFlw = last day flower head put out anthers#sp$endShrivLong = large estimate of how many days styles persisted after last day of flowering (0=shriveled on last day)#sp$endShrivAvg = middle estimate of how many days styles persisted after last day of flowering#sp$endShrivShort = small estimate of how many days styles persisted after last day of flowering#sp$shrivNotes = notes about shriveling#sp$repollinated = date when pollination treatment was reapplied#sp$notes = other notes# checking the data filestr(sp) #structuresp$headIdlevels(sp$treatment)# how many rows received each treatmenttable(sp$treatment)# how many rows do heads havehist(sp$row, breaks= 0:20) #histogram of "how many heads have a row with this number", not of total number of rows on each head# phenology#This is not a representative sample of the population. For my experiment, I selected heads that flowered later than most.# how do I make a bar graph?table(sp$styleDate) #how many rows of styles came out each dayfs <- subset(sp, row == 1)table(fs$styleDate) #how many heads started flowering one day beforetable(fs$lastDayFlw) #how many heads finished flowering each day# subsets for each treatmentsc <- subset(sp, treatment == "control")so <- subset(sp, treatment == "outcross")ss <- subset(sp, treatment == "self")# style persistence after treatmentsummary(sp$styleShriv)summary(sc$styleShriv)summary(so$styleShriv)summary(ss$styleShriv)#How do I compare three proportions in R?# length of style persistencesummary(sp$daysPerstAvg) #overallhist(sp$daysPerstAvg, breaks= 0:18) summary(sc$daysPerstAvg) #controlquartz()hist(sc$daysPerstAvg, breaks= 0:18)summary(so$daysPerstAvg) #outcrossquartz()hist(so$daysPerstAvg, breaks= 0:18)summary(ss$daysPerstAvg) #selfquartz()hist(ss$daysPerstAvg, breaks= 0:18)summary(aov(sp$daysPerstAvg~sp$treatment))#Can I add lines to show the high and low estimates, or should I just graph these separately?# length of style persistence after last day of floweringsummary(sp$endShrivAvg) #overallquartz()hist(sp$endShrivAvg, breaks= -12:12) summary(sc$endShrivAvg) #controlquartz()hist(sc$endShrivAvg, breaks= -12:12)summary(so$endShrivAvg) #outcrossquartz()hist(so$endShrivAvg, breaks= -12:12)summary(ss$endShrivAvg) #selfquartz()hist(ss$endShrivAvg, breaks= -12:12)summary(aov(sp$endShrivAvg~sp$treatment))#Can I add lines to show the high and low estimates, or should I just graph these separately?# re-analysis excluding 23-Jul-11# subsets excluding 23-Jul-11rp <- subset(sp, dateTreat != "21-Jul-11")rc <- subset(sc, dateTreat != "21-Jul-11")ro <- subset(so, dateTreat != "21-Jul-11")rs <- subset(ss, dateTreat != "21-Jul-11")# style persistence after treatmentsummary(rp$styleShriv)summary(rc$styleShriv)summary(ro$styleShriv)summary(rs$styleShriv)#How do I compare three proportions in R?# length of style persistencesummary(rp$daysPerstAvg) #overallquartz()hist(rp$daysPerstAvg, breaks= 0:15) summary(rc$daysPerstAvg) #controlquartz()hist(rc$daysPerstAvg, breaks= 0:15)summary(ro$daysPerstAvg) #outcrossquartz()hist(ro$daysPerstAvg, breaks= 0:15)summary(rs$daysPerstAvg) #selfquartz()hist(rs$daysPerstAvg, breaks= 0:15)summary(aov(rp$daysPerstAvg~rp$treatment))#Can I add lines to show the high and low estimates, or should I just graph these separately?# length of style persistence after last day of floweringsummary(rp$endShrivAvg) #overallquartz()hist(rp$endShrivAvg, breaks= -12:12) summary(rc$endShrivAvg) #controlquartz()hist(rc$endShrivAvg, breaks= -12:12)summary(ro$endShrivAvg) #outcrossquartz()hist(ro$endShrivAvg, breaks= -12:12)summary(rs$endShrivAvg) #selfquartz()hist(rs$endShrivAvg, breaks= -12:12)summary(aov(rp$endShrivAvg~rp$treatment))#Can I add lines to show the high and low estimates, or should I just graph these separately?# analysis of first four rows only# subsets of first four rows onlyep <- subset(sp, row < 5)ec <- subset(sc, row < 5)eo <- subset(so, row < 5)es <- subset(ss, row < 5)# style persistence after treatmentsummary(ep$styleShriv)summary(ec$styleShriv)summary(eo$styleShriv)summary(es$styleShriv)#How do I compare three proportions in R?# length of style persistencesummary(ep$daysPerstAvg) #overallquartz()hist(ep$daysPerstAvg, breaks= 0:15) summary(ec$daysPerstAvg) #controlquartz()hist(ec$daysPerstAvg, breaks= 0:15)summary(eo$daysPerstAvg) #outcrossquartz()hist(eo$daysPerstAvg, breaks= 0:15)summary(es$daysPerstAvg) #selfquartz()hist(es$daysPerstAvg, breaks= 0:15)summary(aov(ep$daysPerstAvg~ep$treatment))#Can I add lines to show the high and low estimates, or should I just graph these separately?# length of style persistence after last day of floweringsummary(ep$endShrivAvg) #overallquartz()hist(ep$endShrivAvg, breaks= -12:5) summary(ec$endShrivAvg) #controlquartz()hist(ec$endShrivAvg, breaks= -12:5)summary(eo$endShrivAvg) #outcrossquartz()hist(eo$endShrivAvg, breaks= -12:5)summary(es$endShrivAvg) #selfquartz()hist(es$endShrivAvg, breaks= -12:5)summary(aov(ep$endShrivAvg~ep$treatment))#Can I add lines to show the high and low estimates, or should I just graph these separately?