We are trying to understand the impact of number of workdays on sales.

Please find reprex below:

```

library(tidyverse)

# Work days for January from 2010 - 2018

data = data.frame(work_days = c(20,21,22,20,20,22,21,21),

sale = c(1205,2111,2452,2054,2440,1212,1211,2111))

# Apply linear regression

model = lm(sale ~ work_days, data)

summary(model)

Call:

lm(formula = sale ~ work_days, data = data)

Residuals:

Min 1Q Median 3Q Max

-677.8 -604.5 218.7 339.0 645.3

Coefficients:

Estimate Std. Error t value Pr(>|t|)

(Intercept) 2643.82 5614.16 0.471 0.654

work_days -38.05 268.75 -0.142 0.892

Residual standard error: 593.4 on 6 degrees of freedom

Multiple R-squared: 0.00333, Adjusted R-squared: -0.1628

F-statistic: 0.02005 on 1 and 6 DF, p-value: 0.892

```

Could you please help me understand if the coefficients

Every work day decreases the sale by 38.05 ?

##############################################

```

data = data.frame(work_days = c(20,21,22,20,20,22,21,21),

sale = c(1212,1211,2111,1205,2111,2452,2054,2440))

model = lm(sale ~ work_days, data)

summary(model)

Call:

lm(formula = sale ~ work_days, data = data)

Residuals:

Min 1Q Median 3Q Max

-686.8 -301.0 -8.6 261.3 599.7

Coefficients:

Estimate Std. Error t value Pr(>|t|)

(Intercept) -6220.0 4555.9 -1.365 0.221

work_days 386.6 218.1 1.772 0.127

Residual standard error: 481.5 on 6 degrees of freedom

Multiple R-squared: 0.3437, Adjusted R-squared: 0.2343

F-statistic: 3.142 on 1 and 6 DF, p-value: 0.1267

```

Does this mean,

Every workday increases the sales by 387 ?

How about the negative intercept ?

More Ian Melwil Dsouza's questions See All
Similar questions and discussions