Dear Contributors
I would like to perform this operation using a loop, instead of repeating
the same operation many times.
The numbers from 1 to 4 related to different groups that are in the
database and for which I have the same data.


    x<-c(1,3,7)

datiP1 <- datiP[datiP$city ==1,x];

datiP2 <- datiP[datiP$city ==2,x];

datiP3 <- datiP[datiP$city ==3,x]

datiP4 <- datiP[datiP$city ==4,x];
-- 

Thank you for any help you can provide.

Francesca

        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org 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.

Reply via email to