I have a vector of hourly temperatures (DATA$TEMP) linked to dates (DATA$DATE) and thermometer position (DATA$PLACE).
I want identify the maximum temperature conditional on date and position. I can easily do this one date and position at a time, given I specify each date and position. eg.
x <- max(DATA$TEMP[DATA$DATE =="20/12/15" & DATA$PLACE=="room"])
However I have many dates and positions and would like a function that can run through each date / position combination and return a vector of max temps linked to each.