Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 846083
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T06:33:26+00:00 2026-05-15T06:33:26+00:00

Apart from graphical estimation of linearity (gaze-at-scatterplot method), which is utilized before applying some

  • 0

Apart from graphical estimation of linearity (gaze-at-scatterplot method), which is utilized before applying some technique from GLM family, there are several ways to do this estimation arithmetically (i.e. without graphs).

Right now, I’ll focus on Fisher’s eta-squared – correlation ratio: arithmetically, it’s equal to squared Pearson’s r (coef. of determination: r2) if relationship between two variables is linear. Hence, you can compare values of eta and r and make an assessment about type of relation (linear or not). It provides an information about percent of variance in the dependent variable explained (linearly or not) by the independent variable. Therefore, you can apply it when linearity assumptions are not met.

Simply stated: is there a routine for eta/eta-squared in R?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T06:33:27+00:00Added an answer on May 15, 2026 at 6:33 am

    I’m still quite stunned, I must admit… there’s no easy and straightforward way for calculating η or η2 in R… So I wrote a function according to Wikipedia page. Here goes:

    eta <- function(x, squared = FALSE, ...) {
        stopifnot(is.list(x))
        ## unlist
        y <- unlist(x)
        ## group mean
        mg <- rapply(x, mean, ...)
        ## group size
        ng <- rapply(x, length, ...)
        ## total mean
        mtot <- mean(y, ...)
        ## SSb
        ssb <- sum(ng * (mg - mtot) ^ 2)
        ## SSt
        sst <- sum((y - mtot) ^ 2)
        # get eta-squared
        if (squared) {
          res <- ssb/sst
        # get eta
        } else {
          res <- sqrt(ssb/sst)
        }
        return(res)
    }
    

    So this yields another question, which I’m about to post shortly… what do you use to check linearity? However, I can’t calculate p-values, so if anyone knows how to do it… please, let me know!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Apart from jQuery, which other JavaScript libraries support Visual Studio2005/2008 intellisense integration?
Apart from C++, which non-toy languages have direct or easy-to-use compatibility to C? As
Apart from the fact people get to view the app in a browser which
Apart from the standard [[MyClass alloc] init] pattern, some objects are built from static
Apart from rewriting a lot of XSLT code (which I'm not going to do),
Apart from the books available from Kitware , I am looking for some links
Apart from rolling my own collection, I'm wondering which existing (.NET 3.5) Collection and
Apart from setOnCheckedChangeListener , is there any way through which I can check that
Apart from @staticmethod and @classmethod ? Most languages have some basic libraries making use
Apart from what is shown in the NXP websites regarding mifare plus and mifare

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.