Plotting multiple species accumulation curves in R - r

I am trying to plot multiple curves on one plot. I have managed to produce the curves individually but can't get them all on the same plot.
I have tried the add=TRUE function which isn't working.
When using this line of code
caw<- plot(specaccum(cs, method = "exact"))
Nothing is saving to the data section on the right. It's just saying NULL (empty). Which could be the issue but I am unsure how to move forward?

Related

Is ggplot able to plot this density graph? Does anyone know what this is called? I am trying to plot this graph for my e-greedy results

I am trying to replicate this plot for my e-greedy algorithm results on a 1000 different trials, preferrable using ggplot in R. However, I do not know the name of this type of plot, does anyone happen to know?

How to remove box and whiskers from plot() function in R?

I'm trying to do a very simple plot using the plot() function in R where I plot out the weights and diets of chicks in a stratified plot. For other simple plots like this I've been able to just use the plot() function and it's gone fine. But for some reason, R insists on plotting this as a box-and-whiskers chart instead of plotting all the values themselves. I've tried many different solutions I've found on the Web, from box=FALSE to box=0 to bty="n" to type="p" but nothing works. R always plots it as a box-and-whiskers chart. I can use whisklty=0 to get rid of the whiskers, but nothing I've tried (including all possible combinations of the above solutions) will replace the boxes with the actual values I want.
If the x-axis data is categorical, plot will return a boxplot by default. You could run plot.default() instead of plot() and that will give you a plot of points.
Compare, for example:
plot(iris$Species, iris$Petal.Width)
plot.default(iris$Species, iris$Petal.Width)
If you type methods(plot) in the console, you'll see all of the different kinds of plots the plot function returns, depending on what type of object you give it. plot.default is the "method" that gets dispatched when you provide plot with two columns of numbers. plot.factor gets dispatched when the y-values are numeric and the x-values are categorical (run ?plot.factor for details). If you do plot(table(mtcars$vs, mtcars$cyl)) the plot.table method gets dispatched. And so on.

Scatter plots in R. Why am I getting boxes around certain points?

Apologies, this is probably the simplest question. I'm having trouble making a scatterplot in R Studio. I am trying to see if amphipod counts are correlated to oxygen content. Whenever I plot this using:
plot(Amphipod~Oxygen...ml.l.)
I get a graph with boxes around certain points and I have no idea why. Only 5 points and I can't see anything different about those.

R: getting data (instead of plot) back from sm.density.compare

I'm doing a density compare in R using the sm package (sm.density.compare). Is there anyway I can get a mathematical description of the graph or at least a table with number of points rather than a plot back? I would like to plot the resulting graphs in a different application, but need the data to do so.
Thanks a lot for the help,
culicidae

R statistics: Drawing multiple plots in RGL

Does anyone know how to draw multiple 3d plots in one picture using RGL in R Statistics.
I have three variables and each of those variables belong to two groups. I want each group to have a different color so I can visualize it. In regular R stats, I just use subset and then use par(new=T). I haven't seen anything equivalent for the 3d plot. Does anyone have any suggestion?
Thanks!
try plot3d(x, y, z, add=TRUE)
Admittedly I was a bit surprised when it worked, I thought it would throw an error on the first plot, but i guess it creates an existing plot if none exists and otherwise adds the points to the existing plot

Resources