Given

studentNumbers<-10;

subjEnglish<-sample(-1:100,studentNumbers,replace=TRUE);

when subEnglish <=0, 'U'
                        <=39, 'F'
                        <=49 'D'
                        <=59, 'C'
                        <=69, 'B'
                        <=79,'A'
                        <=100 'A+'
I can solve this using a series of 'if' 'else' statements. I am looking for a 
simple expression that will give the letter classification for every element of 
subEnglish. 


Is there on?

Thanks.

        [[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