Here is a runable program. When I plot Day and Wgt, it graphs all the data
points. All I need is daily.sub1 plotted. I also need each "Tanks" to have
its own col or pch. When I run it with the line with pch, it gives me
nothing.
rm(list=ls())
Trial<-rep(c(1,2),each=12)
Tanks=rep(c("a3","a4","c4","h4"),each=3,2)
Day=rep(c(1:12),2)
Wgt=c(1:24)
daily<-cbind(Trial, Tanks, Day, Wgt)
daily
daily.sub<-subset(daily, subset=Trial==2 & Tanks=="a4"|Trial==2 &
Tanks=="c4"|Trial==2 & Tanks=="h4")
daily.sub1<-as.data.frame(daily.sub)
attach(daily.sub1)
daily.sub1
x11()
plot(Day, Wgt)
#plot(Day, Wgt, pch=c(2,19,21)[Tanks])
detach(daily.sub1)
--
M. Keith Cox, Ph.D.
Alaska NOAA Fisheries, National Marine Fisheries Service
Auke Bay Laboratories
17109 Pt. Lena Loop Rd.
Juneau, AK 99801
[email protected]
[email protected]
U.S. (907) 789-6603
[[alternative HTML version deleted]]
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.