+ Reply to Thread
Results 1 to 5 of 5

Thread: Variability within the group

  1. #1
    Points: 9, Level: 1
    Level completed: 17%, Points required for next Level: 41

    Posts
    2
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Variability within the group




    Hello,

    I apologize if my question seems basic. I have the following data :

    Code: 
     a=c(107,135,122,67,65,53,19,32)
     b=c(35.5,26,9,4.5,5.33,9.83,0,1)
    I predict that one variability within one group will resemble to the other group, even I don't have the same quantities. In other words, the evolution of values follow the same rule in the two groups.

    I want to know which type of analyses I need to run ?

    Thanks a lot.

  2. #2
    Omega Contributor
    Points: 38,303, Level: 100
    Level completed: 0%, Points required for next Level: 0
    hlsmith's Avatar
    Location
    Not Ames, IA
    Posts
    6,993
    Thanks
    397
    Thanked 1,185 Times in 1,146 Posts

    Re: Variability within the group

    This work for you:


    Code: 
    a=c(107,135,122,67,65,53,19,32)
    b=c(35.5,26,9,4.5,5.33,9.83,0,1)
    y <- c(a, b)
    group <- as.factor(c(rep(1, length(a)), rep(2, length(b))))
    install.packages("Rcmdr")
    library(Rcmdr)
    levene.test(y, group)

    Variances are statistically different between samples.
    Stop cowardice, ban guns!

  3. The Following User Says Thank You to hlsmith For This Useful Post:

    Ranfly (08-09-2017)

  4. #3
    Points: 9, Level: 1
    Level completed: 17%, Points required for next Level: 41

    Posts
    2
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: Variability within the group

    Thanks a lot for your reply.

    Ok I see so I reject my H0 that claim that variances are not significantly different isn't ?

    Also, you used levene test, before I posted this, I asked myself, why not using t.test that calculate : variance within group / variance between group
    Also, why not calculating correlation that can be an indicator of the intesnity of relation between variables ? (I've done that I have p<0.05 and coef correlation of 0.73)

    I mean, how do you choose the statistical test in this context, this is the kind of question i'm stack with everytime I want to explore my data

  5. #4
    Omega Contributor
    Points: 38,303, Level: 100
    Level completed: 0%, Points required for next Level: 0
    hlsmith's Avatar
    Location
    Not Ames, IA
    Posts
    6,993
    Thanks
    397
    Thanked 1,185 Times in 1,146 Posts

    Re: Variability within the group

    Levene test is used to test equality in variance between two independent samples. As you know, it is used to decide if the pooled variance or weighted variance should be used in the ttest.


    You could also use two histograms (or overlaid histograms) to visualize data. Yeah, it just takes time to slowly increase your arsenal of procedures you remember to use during descriptive stats.
    Stop cowardice, ban guns!

  6. #5
    TS Contributor
    Points: 12,227, Level: 72
    Level completed: 45%, Points required for next Level: 223
    rogojel's Avatar
    Location
    I work in Europe, live in Hungary
    Posts
    1,470
    Thanks
    160
    Thanked 332 Times in 312 Posts

    Re: Variability within the group


    Quote Originally Posted by Ranfly View Post
    I asked myself, why not using t.test that calculate : variance within group / variance between group
    Also, why not calculating correlation that can be an indicator of the intesnity of relation between variables ? (I've done that I have p<0.05 and coef correlation of 0.73)

    I mean, how do you choose the statistical test in this context, this is the kind of question i'm stack with everytime I want to explore my data
    hi,
    on a more general note: you need to have one or more "real life" questions you want to answer with your data: e.g. group A is more variable then group B, or group A tends to have larger values etc. THEN, you translate the question to statiscal terms, like: the variance in A is different (larger) then in B. Then, you can search for a statistical test that will answer the translated question (Levene's being a good candidate, the t-test a very poor one for the variance) Then check the prerequisites for the chosen test and if applicable run the test.

    regards

  7. The Following User Says Thank You to rogojel For This Useful Post:

    GretaGarbo (08-10-2017)

+ Reply to Thread

           




Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts






Advertise on Talk Stats