I have done a Logistic regression in r with 3 variables involving 1 interation:
weekday is a factor - 7 days of the week.
The coef values are :
Estimate (Intercept) -14.81119721 Vol 0.118819705 weekday2 -24.30795615 weekday3 -4.634180612 weekday4 -21.64229775 weekday5 0.607492058 weekday6 42.80131468 weekday7 19.16098601 heads 0.059934818 weekday2:heads 0.026481088 weekday3:heads 0.006665015 weekday4:heads 0.022825105 weekday5:heads 0.005045576 weekday6:heads -0.041724212 weekday7:heads -0.019254475
From my Understanding below is what I do in excel:
intercept + (coef of vol * vol)+ (coef of corresponding week days) + #there no is value for weekday 1 (coef * head)+ (coef of corresponding weekday:head * head) #no value for weekday1 so it will be zero.
The sum of the above should be equal to predict() value - but I am not able to match it. Could you please explain where I have done wrong in calculating predicthead value using excel?