0% found this document useful (0 votes)
8 views

Example 1

This document embeds R code examples from a Kruskal-Wallis test help page into a LaTeX document. It runs a Kruskal-Wallis test on air quality data that shows ozone levels vary significantly between months. Finally, it includes a boxplot of the air quality data with ozone on the y-axis and month numbers on the x-axis to visualize the variations between months.

Uploaded by

Wilians Santos
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
8 views

Example 1

This document embeds R code examples from a Kruskal-Wallis test help page into a LaTeX document. It runs a Kruskal-Wallis test on air quality data that shows ozone levels vary significantly between months. Finally, it includes a boxplot of the air quality data with ozone on the y-axis and month numbers on the x-axis to visualize the variations between months.

Uploaded by

Wilians Santos
Copyright
© Attribution Non-Commercial (BY-NC)
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Sweave Example 1

Friedrich Leisch May 21, 2012


In this example we embed parts of the examples from the kruskal.test A help page into a L TEX document: > data(airquality, package="datasets") > library("stats") > kruskal.test(Ozone ~ Month, data = airquality) Kruskal-Wallis rank sum test data: Ozone by Month Kruskal-Wallis chi-squared = 29.2666, df = 4, p-value = 6.901e-06 which shows that the location parameter of the Ozone distribution varies signicantly from month to month. Finally we include a boxplot of the data:

150

100

q q q q

50

You might also like