[R] draw with plotrix

Luigi Marongiu m@rong|u@|u|g| @end|ng |rom gm@||@com
Thu Aug 27 13:56:59 CEST 2020


Hello,
I have a dataframe as follows
```
x = c(rep("1000 pmol", 2), rep("100 pmol", 2), rep("10 pmol", 2),
rep("0 pmol", 2))
y = c(2.7642, 2.8192, 2.1976, 2.2816, 1.8929, 1.8883, 1.0051, 0.8561)
z = c(rep("Sample",6), rep("Control", 2))
Q = data.frame(x, y, z, stringsAsFactors = FALSE)
```
I am trying to use plotrix to draw y broke down by x and differentiate
the markers by z, but I get:
```
> brkdn.plot(
+   y, groups=x, obs=z,
+   data=Q, mct="mean", md="std.error",
+   stagger=NA, dispbar=TRUE,
+   type="p", pch=16,
+   main="Measurement",
+   xlab=expression(bold("Amount of probe")),
+   ylab=expression(bold("Optical density"))
+ )
Error in .subset2(x, i, exact = exact) : no such index at level 1

```
and similar with other combinations (`obs = x`...).
What is the correct syntax?
Thank you


-- 
Best regards,
Luigi



More information about the R-help mailing list