r pogram data frame
Title
Question
plot(captaincy $names,captaincy $played)
Error in plot.window(...) : need finite 'xlim' values
In addition: Warning messages:
1: In xy.coords(x, y, xlabel, ylabel, log) : NAs introduced by coercion
2: In min(x) : no non-missing arguments to min; returning Inf
3: In max(x) : no non-missing arguments to max; returning -Inf
how to do plot in view mode
R Introduction-to-Data-Frames-in-R 06-07 min 50-60 sec
Answers:
Generally, RStudio has four windows: Source, Console, Environment, and Plots. If the Plots window has been minimized, the plot would not be generated. Please ensure that you have Plots windows enabled.
Another possible cause of this message is attempting to use character values as X or Y data.In this case , captain names falls into the character values criteria. So use
plot(factor(captaincy$names),captaincy$played)
Even I faced similar problem but using plot(factor(captaincy$names),captaincy$played)plotted the data
Login to add comment