0
what is the answer in blank space ofr the print(x) statement?
Filtering Data Fill in the blanks to find the average "qsec" of mtcars that have "hp" greater than 100 and "gear" less than 5. x <- mtcars[mtcars $hp > 100 & mtcars$gear< 5 , 'qsec'] print( (x))
2 Respostas
0
Your code is difficult to read and it is unclear where blank spaces would be. The task asks you to output the average.
Please specify which task it is (lesson number).
0
Use the mean() function since it is asking for an average.
x <- mtcars[mtcars$hp > 100 & mtcars$gear < 5, 'qsec']
print(mean(x))