Find the maximum temperature on May

0 votes

I'm working with the airqualiy data-set:

I need to Find the maximum temperature on May

Oct 5 in Data Analytics by anonymous
• 120 points
36 views

1 answer to this question.

0 votes

Hi,

You can perform your requirement in steps. For example, you can sort the temperature first then find the maximum one depending on the month. You can take help from the below-given example.

require(data.table)
DT=as.data.table(airquality)
DT[,.SD[which.max(Temp)],by=Month]
     Month Ozone Solar.R Wind Temp Day
[1,]     5    45     252 14.9   81  29
[2,]     6    NA     259 10.9   93  11
[3,]     7    97     267  6.3   92   8
[4,]     8    76     203  9.7   97  28
[5,]     9    73     183  2.8   93   3
answered Oct 6 by MD
• 79,930 points

Related Questions In Data Analytics

0 votes
1 answer

Plotting multiple graphs on the same page in R

If you want to plot 4 graphs ...READ MORE

answered Mar 27, 2018 in Data Analytics by Bharani
• 4,580 points
233 views
0 votes
1 answer

How to find out the sum/mean for multiple variables per group in R?

You can use the reshape2 package for ...READ MORE

answered Apr 12, 2018 in Data Analytics by DataKing99
• 8,210 points
1,666 views
0 votes
1 answer

Save a plot as image on the disk using R

Consider for both the situations: 1. Image will ...READ MORE

answered Apr 13, 2018 in Data Analytics by Sahiti
• 6,320 points
680 views
0 votes
1 answer

Plot two variables as lines on the same graph using ggplot

If you have small number of variables, ...READ MORE

answered Apr 17, 2018 in Data Analytics by kappa3010
• 2,090 points
2,434 views
+1 vote
1 answer

How to convert a list of vectors with various length into a Data.Frame?

We can easily use this command as.data.frame(lapply(d1, "length< ...READ MORE

answered Apr 4, 2018 in Data Analytics by DeepCoder786
• 1,720 points
423 views
0 votes
2 answers

In data frame how to spilt strings into values?

You can do this using dplyr and ...READ MORE

answered Dec 4, 2018 in Data Analytics by Kalgi
• 51,970 points
184 views
0 votes
1 answer
0 votes
1 answer

How to convert a text mining termDocumentMatrix into excel or csv in R?

By assuming that all the values are ...READ MORE

answered Apr 5, 2018 in Data Analytics by DeepCoder786
• 1,720 points
504 views
0 votes
1 answer
0 votes
1 answer

R program: Filter and re-arrange data based on multiple conditions

Hi, You need to create your own customized ...READ MORE

answered Jul 27 in Data Analytics by MD
• 79,930 points
306 views