Skip to content
Prev 26852 / 29559 Next

Subsetting dataframe by all factor levels

On Fri, 14 Sep 2018, Justin H. wrote:

            
Justin,

   The results have sites with 'NA' for the mean precipiation despite having
recorded values some days. For example,
0
Blazed Alder                              NA

while
name easting northing   elev   sampdate prcp
7741 Blazed Alder 2393589 196840.8 1112.5 2005-01-01  0.2
7742 Blazed Alder 2393589 196840.8 1112.5 2005-01-02  0.2
7743 Blazed Alder 2393589 196840.8 1112.5 2005-01-03  0.4
7744 Blazed Alder 2393589 196840.8 1112.5 2005-01-04  0.0
7745 Blazed Alder 2393589 196840.8 1112.5 2005-01-05  0.0
7746 Blazed Alder 2393589 196840.8 1112.5 2005-01-06  0.0

   I'll read up on tapply and see if I can identify the reason for the
discrepancy.

Regards,

Rich