Releveling to Calculate Mean and Standard Error

Let's take a look at releveling for mean and standard error.

The relevel() function in R

One limitation of the outputoutput2 of the table of coefficients is that we don’t have the mean and standard error of the other pollination treatment level. It’s a simple process to calculate the mean through by hand, but the standard error can’t be calculated in this way. Instead, we can use R to estimate the mean and standard error for the self-pollinated plants by using the relevel() function to set this treatment as the intercept, as shown in the code widget below:

Get hands-on with 1200+ tech skills courses.