₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,330,906 members, 8,447,660 topics. Date: Saturday, 18 July 2026 at 06:01 PM

Toggle theme

Help With Statistics Problem - Education (2) - Nairaland

Nairaland ForumNairaland GeneralEducationHelp With Statistics Problem (2240 Views)

1 2 Reply (Go Down)

Re: Help With Statistics Problem by ishmael(m): 1:23am On Jul 22, 2012
aletheia: ^
Taking it some few steps further:
Let's fit the regression equation in order to help Jayjuice. . .I usually use R for most of my statistical work so. . .these commands in R:

year=1:5
amount.per.year=c(1000,1300,1800,2000,2200)
eqn=lm(amount.per.year ~ year)
summary(eqn)

. . .will produce the following as part of the output:

Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 730.00 106.61 6.847 0.00638 **
year 310.00 32.15 9.644 0.00237 **


Recall the regression equation: y = a + bx where y is the dependent (or predicted) variable which in this case is Amount, a is the Intercept, and b is the slope or regression coefficient and x is the independent (or predictor) variable, which in this case is Year. Plugging in the highlighted values from the output above gives a regression equation:
                           y = 730.00 + 310.00*x

And so substituting the x=6 and x=7 respectively gives you your predicted amounts for years 6 and 7.

In R predicting for years 6 and 7 is sort of:
predict(eqn, as.data.frame(c(6:7)))

Though this technically is how it should read:

> year=append(year, 6:7)
> predict(eqn, as.data.frame(year))
1 2 3 4 5 6 7
1040 1350 1660 1970 2280 2590 2900


But bear in mind that strictly speaking. . .
Thanx for ur contributions too. I use R too, but i prefer spss and minitab most of the time for issues like these since i would not have to write any codes. Are u a statistician? statisticians are great and wonderful.
Re: Help With Statistics Problem by aletheia(m): 2:54am On Jul 22, 2012
ishmael: Thanx for ur contributions too. I use R too, but i prefer spss and minitab most of the time for issues like these since i would not have to write any codes. Are u a statistician? statisticians are great and wonderful.
^
Well, I have a Masters in Epidemiology and Biostatistics. Thanks for the compliment. I generally prefer using R and on occasion Stata and SAS.
Re: Help With Statistics Problem by ishmael(m): 7:25am On Jul 22, 2012
aletheia: ^
Well, I have a Masters in Epidemiology and Biostatistics. Thanks for the compliment. I generally prefer using R and on occasion Stata and SAS.
Ah, that means u're a coding master. Stata and sas are similar, i've used them before too. Pls do u use Epi info? Do u have the software to send to me if it's not too bulky? I'm also a statistician, with Msc in view. Regards.
Re: Help With Statistics Problem by aletheia(m): 2:08pm On Jul 22, 2012
ishmael: Ah, that means u're a coding master. Stata and sas are similar, i've used them before too. Pls do u use Epi info? Do u have the software to send to me if it's not too bulky? I'm also a statistician, with Msc in view. Regards.
I started out using Epi Info and I teach in an annual workshop on Epi Info for medical doctors, but these days I usually only use it for data entry purposes. . .though I am now shifting to Epidata for data entry.
Which software specifically do you want me to send to you?
Re: Help With Statistics Problem by ishmael(m): 2:52pm On Jul 22, 2012
aletheia: I started out using Epi Info and I teach in an annual workshop on Epi Info for medical doctors, but these days I usually only use it for data entry purposes. . .though I am now shifting to Epidata for data entry.
Which software specifically do you want me to send to you?
i need Epi info and cspro. I have some clients that want me to take them on it. Are u in nigeria or u're abroad? My email add is: ishmaelxy@yahoo.com Regards.
Re: Help With Statistics Problem by aletheia(m): 4:38pm On Jul 22, 2012
ishmael: i need Epi info and cspro. I have some clients that want me to take them on it. Are u in nigeria or u're abroad? My email add is: ishmaelxy@yahoo.com Regards.
You can download Epi Info from the cdc website here: There are 2 flavours - Epi Info 7 (latest one) and Epi Info 3.5.3. I suspect the one you are interested in is the 3.5.3 but you can take a look at the Epi Info 7 version which is smaller.

P.S. I 'll try an send an email later in the week. If you are in Abuja, we can collaborate.
Re: Help With Statistics Problem by ishmael(m): 5:58pm On Jul 22, 2012
aletheia: You can download Epi Info from the cdc website here: There are 2 flavours - Epi Info 7 (latest one) and Epi Info 3.5.3. I suspect the one you are interested in is the 3.5.3 but you can take a look at the Epi Info 7 version which is smaller.

P.S. I 'll try an send an email later in the week. If you are in Abuja, we can collaborate.
ok thanx. I'm in abuja, but will be going to kd 2mrw. Send ur number to my box, i will try and call u.
Re: Help With Statistics Problem by Jayjuice(m): 6:51pm On Jul 22, 2012
aletheia: ^
Taking it some few steps further:
Let's fit the regression equation in order to help Jayjuice. . .I usually use R for most of my statistical work so. . .these commands in R:

year=1:5
amount.per.year=c(1000,1300,1800,2000,2200)
eqn=lm(amount.per.year ~ year)
summary(eqn)

. . .will produce the following as part of the output:

Coefficients:
Estimate Std. Error t value Pr(>|t|)
(Intercept) 730.00 106.61 6.847 0.00638 **
year 310.00 32.15 9.644 0.00237 **


Recall the regression equation: y = a + bx where y is the dependent (or predicted) variable which in this case is Amount, a is the Intercept, and b is the slope or regression coefficient and x is the independent (or predictor) variable, which in this case is Year. Plugging in the highlighted values from the output above gives a regression equation:
                           y = 730.00 + 310.00*x

And so substituting the x=6 and x=7 respectively gives you your predicted amounts for years 6 and 7.

In R predicting for years 6 and 7 is sort of:
predict(eqn, as.data.frame(c(6:7)))

Though this technically is how it should read:

> year=append(year, 6:7)
> predict(eqn, as.data.frame(year))
1 2 3 4 5 6 7
1040 1350 1660 1970 2280 2590 2900


But bear in mind that strictly speaking. . .
thanks alot..i really appreciate
Re: Help With Statistics Problem by ishmael(m): 7:41pm On Jul 22, 2012
Jayjuice: thanks alot..i really appreciate
Hope u now understand the concept of dependent and independent variables?
Re: Help With Statistics Problem by Jayjuice(m): 7:49pm On Jul 22, 2012
ishmael: Hope u now understand the concept of dependent and independent variables?
Yeah i do...thanks...the whole statistics thing is new to me..its interestin tho..good to have gurus like u and alethia in tha house
Re: Help With Statistics Problem by Jayjuice(m): 7:56pm On Jul 22, 2012
...
Re: Help With Statistics Problem by ishmael(m): 6:25am On Jul 23, 2012
Jayjuice: Yeah i do...thanks...the whole statistics thing is new to me..its interestin tho..good to have gurus like u and alethia in tha house
Good one bro. Alethia is already one of my brothers in statistics now. You can personally contact me thru email any time u need clarification on anything in statistics, especially when i'm not logged on or active on nairaland. My email add is: ishmaelxy@yahoo.com.
Re: Help With Statistics Problem by segun4christ: 10:12am On Jul 23, 2012
what is best statistics text book dat u know ?
1 2 Reply

WAEC Result 2014 Statistics - Mass Failure In English And MathematicsHelp With Statistics ProblemStudent looking for employment statistics for Nigeria234

Ask Me Any Question About IJMB + IJMB FAQHow MY Neighbor's Daughter Duped My Mum Of A Huge Sum Of MoneyWhat Next After Secondary School ?