Dear Forum,

I have a data frame as 

mydat = data.frame(basel_asset_class = c(2, 8, 8 ,8), defa_frequency = c(0.15, 
0.07, 0.03, 0.001))

> mydat
  basel_asset_class defa_frequency
1                 2          0.150
2                 8          0.070
3                 8          0.030
4                 8          0.001


I need to get the subset of this data.frame where no of records for the given 
basel_asset_class is > 2, i.e. I need to obtain subset of above data.frame as 
(since there is only 1 record, against basel_asset_class = 2, I want to filter 
it)

> mydat_a
  basel_asset_class defa_frequency
1                 8          0.070
2                 8          0.030
3                 8          0.001

Kindly guide

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