Synopsis

Pricing is an ordinal but not simpe task. But mistakes in pricing could be reason of big losses. Here is a two simple examples how we can use p-value to preparing pricing decisions. There is a two best selling products that has a almost the same sales - small turning lathe (1830) and metal bender (250). But despite the good sales we will see, that the pricing policy for this products should be very different!

The real dataset is using. There is a data about sales of metalworking equipment in 2016 in the real company. The dataset contains three columns: period - means the sales period (twice in month), sales - sales in national currency and diff - difference with main competitor price of the similar product. Naturally, we can not show the real sales data in this article. But it is not necessary.

Because we are using just two-weeks sales data, it may be so volatile. That is why there is a good idea to use the moving average instead of source sales data.

Examples

Turning lathe 1830

This is good, but not unique product. This model also sells by a lot of competitors.

Let’s see the plot of sales and price difference. The axis of price difference shows at the left. Positive values indicates that competitors price is greater that our price in percents. The sales axis is not shown as descibed above.

#process 1830
x <- sales1830$diff
y <- sales1830$sales
y2 <- ma(sales1830$sales)

plot(y2,type="l",col="red", yaxt='n', ann=FALSE, xaxt = 'n')
par(new=T)
plot(x,type="l",col="blue", xaxt = 'n', ann = FALSE)
legend('bottomright', c('price difference, %','sales'), lty=c(1,1), lwd=c(2.5,2.5),col=c("blue","red")) 

Ok, we can see that probably there is a some correlation between sales and price difference. Let’s calculate linear model and p-value. The NULL hypothesis is there is no correlation between sales and price difference.

fit <- lm (y2 ~ x)
summary(fit)
## 
## Call:
## lm(formula = y2 ~ x)
## 
## Residuals:
##     Min      1Q  Median      3Q     Max 
## -690966 -294374    7450  342009  586876 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1292490     109259  11.830 2.53e-09 ***
## x              42763      12332   3.468  0.00317 ** 
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 415100 on 16 degrees of freedom
## Multiple R-squared:  0.4291, Adjusted R-squared:  0.3934 
## F-statistic: 12.03 on 1 and 16 DF,  p-value: 0.003173

As we can see, the p-value = 0.003173, that so less than 0.05. Thus we rejected the NULL hypothesis and can claim that the price difference is valuable to sales. What it means to business? Obviously the good price strategy for this lathe would be retention of price difference not less than 0-5%, depends on current sales and gross profit. Let’s look other example:

Metal bender 250

This is a unique product! It have some options, that is absent in competitor’s similar products.

#process 250
sales250 <- sales250[complete.cases(sales250),]
x <- sales250$diff
y <- sales250$sales
y2 <- ma(sales250$sales)

plot(y2,type="l",col="red", yaxt='n', ann=FALSE, xaxt = 'n')
par(new=T)
plot(x,type="l",col="blue", xaxt = 'n', ann = FALSE)
legend('bottomright', c('price difference, %','sales'), lty=c(1,1), lwd=c(2.5,2.5),col=c("blue","red")) 

On this plot we can see that the correlation between sales and price difference is not obvious.

fit <- lm (y ~ x)
summary(fit)
## 
## Call:
## lm(formula = y ~ x)
## 
## Residuals:
##      Min       1Q   Median       3Q      Max 
## -1013304  -288892     8324   238721   989424 
## 
## Coefficients:
##             Estimate Std. Error t value Pr(>|t|)    
## (Intercept)  1038012     264395   3.926  0.00099 ***
## x             -42754      30329  -1.410  0.17568    
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 519800 on 18 degrees of freedom
## Multiple R-squared:  0.09942,    Adjusted R-squared:  0.04939 
## F-statistic: 1.987 on 1 and 18 DF,  p-value: 0.1757

And the p-value = 0.1757 does not allow us to reject the NULL hypothesis. Thus we can claim that this product is real USP, that allow us to hold a bigger price and get a more gross profit! In this case the best price policy is to be more expensive than competitor not more than 10-11%.

Couclusion

As shown above, p-value is a good tool to help us understand the situation with pricing. It may help us to hold the bigger price in some cases, or vice versa - to get more sales. This model can be improved. For instance, we should consider seasonality, if it is. And the best practice is use more than 30 periods of sales if it possible, especially for new products.