I've already tried searching but I've found nothing similar.
I have a dataset containing temperatures, and another dataset containing 23 tipes of terrain (categorical variable).
I have drawn a dataset of temperature versus type of terrain, seen a trend in this plot and now I want to extract statistics (i.e. median) from this plot.
This is the code I used for drawing the boxplot:
boxplot(zone$tm_03 ~ ds3_utm$terr, col='chartreuse3', xlab='Terreno', ylab='Temperatura (°C)', varwidth=T)
And this is the boxplot I found:
What I'd like to do is to extract from the boxplot the value of the median for each category. I thought of using boxplot.stats(), but I didn't manage to make it work.
boxplot_stats<-boxplot.stats(zone$tm_01 ~ ds3$terr)
Error in x[floor(d)] + x[ceiling(d)] :
non numeric argument transformed in binary operator
Inoltre: Warning messages:
1: In is.na(x) :
is.na() applied to non-(list or vector) of type 'language'
2: In is.na(x) :
is.na() applied to non-(list or vector) of type 'language'
3: In is.na(x) :
is.na() applied to non-(list or vector) of type 'language'
And summary():
> summary(boxplot(zone$tm_03 ~ ds3_utm$terr, col='chartreuse3', xlab='Terreno', ylab='Temperatura (°C)', main='Marzo', varwidth=T))
Errore in summary(boxplot(zone$tm_03 ~ ds3_utm$terr, col = "chartreuse3", :
error in evaluating the argument 'object' in selecting a method for function 'summary': Errore in eval(expr, envir, enclos) : oggetto "ds3_utm" not found.
Anyone can help me?
Thanks in advance!
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…