About this example
R’s datasets::airquality holds daily air-quality readings from New York between May and September 1973, from the New York State Department of Conservation and the National Weather Service. Ozone was not recorded on 37 of the 153 days. Those cells stay as NA: the editor counts them as missing for their month and never treats them as zero.
The months differ in how many readings they have: 26 in May, July and August, 29 in September and only 9 in June, when 21 days are missing. With fewer than 10 values an outline mostly reflects the bandwidth rather than the data, so June keeps its points even if you hide points elsewhere, and the figure says so. Report the accepted n with each month.
July and August reach well above 100 ppb, which widens their bandwidths to about 15 and 19 ppb; May and September stay near 7 ppb. Because each violin is trimmed to its own lowest and highest reading, no outline suggests ozone values that were never measured.
Sources: R datasets::airquality — NY State Dept. of Conservation, National Weather Service
The data
| Month | Ozone (ppb) |
|---|---|
| May | 41 |
| May | 36 |
| May | 12 |
| May | 18 |
| May | NA |
| May | 28 |
| May | 23 |
| May | 19 |
| May | 8 |
| May | NA |
| May | 7 |
| May | 16 |
| May | 11 |
| May | 14 |
| May | 18 |
…and 138 more rows. Open the example to see all of them.
These are individual observations, not supplied group summaries. The editor reports its interpretation and preserves your selected presentation when loading an example. Open the example, replace the data with your own, and export the figure as SVG, PDF, PNG or TIFF.