| ||||||||||
Line: 228 to 228 | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
Again looks very good. | ||||||||||
Added: | ||||||||||
> > |
Data frames and CombinationsCreate a list containing two columns with a count form 1 to 31L<-list(A=c(1:31),B=c(1:31))
Create a data frame that contains all the combinations 1 to 31
G<-expand.grid(L)
Add a column, excel style:
G$fraction <- G$A/G$B
Filter by column:
G[G$fraction <= 1,]Count the number of rows of a dataframe: nrow (G[G$fraction <= 1,]) | |||||||||
|