I was working on RStudio with some data. I have sales data of a product month wise and the warranty expenses incurred for it monthly. Over the years, the months were entered in various nomenclatures making it hard for me to filter the data according to month. The data is as follows:
Month
Apr
APR-13.
APR-14.
APR-15.
Aug
AUG-12.
AUG-13.
AUG-14.
AUG-15.
Dec
DEC-12.
DEC-13.
DEC-14.
DEC-15.
Feb
FEB-13.
FEB-14.
FEB-15.
Jan
JAN-07.
JAN-13.
JAN-14.
JAN-15.
Jul
JUL-12.
JUL-13.
JUL-14.
JUL-15.
....
....
I wanted to subset the above data according to the months.
I tried to use the subset
function of the R.
subset(SR,SR$Month=='Apr')
The above code is giving only the results of the Month 'Apr' instead of giving the data of all months which contain Apr.