The essense of product pricing

Here is enough space for all players to ask questions about the game.

Moderator: moderators

Guest

The essense of product pricing

Post by Guest » 04.04.2009, 05:54

I've been sitting on this for a long, long time as a tool I wanted to keep to myself. Then a while ago I decided to share, but got busy and forgot. However, recent run-ins with Azer Productions and a friendly "hello" from FelixBluIndustries reminded me that I wanted to share some love with the Kapilands community.

So a little backstory: The first product I chose to make when I started Kapilands was Wine. Something about the Vineyards of Knolls or the Knolls of Vineyards or something witty like that. However, after a few days of this I realized that my ROI just wasn't matching up to what others were achieving - not even close.

I investigated a little, and found that there was general advice: Leather Jackets, or Gas, or Wardrobes. And sure enough, those were better profits. But were they they best? Was anything else decent? How could we know for sure? I wanted to find out.

So I set about gathering data. Now the production side is easy. You can just look up the costs, rates, and inputs. So the first thing I did was make a linked spreadsheet with all the recipes interlinked, and a column for the current market price. Then I could just fill in that column and it would autocalculate the cost of any product based on the market value of the components (plus manufacturing cost of course).

This was a decent start. It let me know what was selling above or below price on the market. Car parts were of course one of the worst, since steel is so valuable and cars are apparently not. Also my perennial favorite poster child for losing money, Cattle, of course showed up. So did a few other things (like Wine as I'd already known), and I had an idea of what to avoid.

This was useful and I know for a fact that other spreadsheet-friendly folks have done just about the same thing.

However, market prices are of course set by players, and I wasn't trying to figure out what players thought were the best or worst products already. I wanted to know what they SYSTEM treated as the best and worst products. (And besides, some of those were so thinly traded with just a few listed in the market at high prices that I had no idea what was realistic.

Achieving this goal meant I needed to get the other side of the economy: what the store results are. So I went about building all the different stores and selling some of everything. But the problem is what price to use. It's always important to maximize my profit (as described here)). I needed to know what the optimized price was because it wouldn't be fair to compare a right-priced product against an overpriced one and an underpriced one. But I couldn't just use market prices which I'd already said weren't reliable.

A better way to get the midpoint was to figure out where the price should be if all producing buildings were generating the same ROI. Obviously that isn't true, but what it does is push the balance to the end of the chain: the store. This meant that whatever rate I picked wouldn't matter as long as it was somewhere in the middle of the store results. For example:
  • Suppose I pick 20%. I calculate optimal store ROI for gas at 8% and Cars at 2%. Well that is not reasonable because clearly the factory is getting overpaid. And since cars go through more steps, I'm building in that 20% profit many more times but not counting it.

    However, suppose I use 10% instead. Gas in the store is 15% ROI at optimum, and Cars are 4%. Now the 10% is much more fair because it underestimates the gas factory and overrates the car factory.
The catch here is that even with a known cost, optimal price is not something you can just hit on. It takes a lot of data, and I was doing this for every product. Then add in the complication that I was going to revise those costs once I had better market knowledge, and suddenly my time measurements weren't even in the right ballpark.

So what I needed to do was figure out a shortcut for every product. A way that, without going into the game and trying over and over, I could predict what a retail time would be at a given price. So I gathered a spread of data in all products and attempted to reverse-engineer the formula.

And this is the meat, the essence of product pricing. People have asked me for this over the years and I never gave it out, but now I will share the formula for calculating selling time based on price.

Now first, a few caveats. There are some variables that I couldn't vary and so I just baked them in together. Average price and average quality being foremost on this list. This was close to the game start so quality was still close to zero in all products. And average price - while it does matter, the difference has never shown to be large enough to significantly shift profitability. Also I'm sure this is a greatly simplified version of what the game actually does. However, months later I still found that my spreadsheet estimates for time remained reasonably close. And you'll recall that the profitability curve is pretty flat at the top, so being a little off is forgiveable when you consider how far off people's raw guesses generally are.

So anyway, here's the formula:

Code: Select all

(Price ^ 3.5 - A) / B = Time in minutes to sell 1 in a 100m store.
Where A and B are two numbers that set the basis for any product. Now that list of numbers I'll attach at the bottom. But first, let me point out that anyone familiar with moderate Algebra can take just two sample price/time pairs and solve for A and B themself. The key part is the formula's structure. So if you try this and find that my numbers don't match the way you want them to, recalculate A and B and then see if this isn't predictive at other prices.

And again, this is a bit simplified. In part it's using a line to estimate a flat curve. So you won't get A and B to be exactly the same even with varying points of your own data over and over. But they're close enough to count.

Now one cool thing about this is that if you are familiar with Excel's SOLVER tool, you can just ask Excel to find the optimal price for you! (If you're not familiar with it, you should go learn, though it's outside the scope of this guide.)

But anyway, back to my story. What I had then were the costs all linked together, and the ability to calculate optimal pricing for any product. All I needed were two more data points, the prices of two products. Care to guess which two?

Those two products, spelled backwards to avoid spoilers, are r-e-t-a-w and r-e-w-o-p. Because naturally they don't use inputs, but everything else builds from them.

So given that, I had complete information. From this I was able to compile the "Knolls List" that I've talked about elsewhere: the 10 products I felt were the most profitable in the system, regardless of what the players do. Gas and Leather Jackets both top the list. If you run a gas business buying power but producing everything else yourself, you effectively make 7.1% ROI on every building. Leather jackets, 7.7%. I personally liked Pullovers and Leather Gloves at 4.2% each.

Everything else in the game is lower than that. Now you can do better by focusing on just the best part of a chain and letting someone else do the unprofitable part. But in the wide view, that's why those are the best businesses.

Now you're probably thinking "OK, so just give us the workbook." To be honest I was going to, but believe me when I tell you that it's an unreadable mess. I was figuring a lot of this out as I went along, so there are dead ends and calculations that don't mean much. The good values are hidden amidst odd or archaic columns. I wrote it and I can barely figure out where to look. If you're really interested in this, you can take the raw info and make something much cleaner.

However, to save time I did publish one sheet, here:
http://spreadsheets.google.com/ccc?key= ... 01tf-_vrdQ
which includes all the linked self-calculating costs. If the formulas look odd at first, it's because I named the cells for easy reference. One quirk of that sheet as currently written is that I made the Market Premium the manual entry and the Market Price an autocalc, instead of the other way around. You'll also notice the next two columns are Raw Input and Raw Total Cost. Basically the same thing as Input Cost and Total Price, except I excluded the Market Premium at all steps.

So when I tell you that's the neatest sheet, you should believe that the rest is just unreadable.

So instead, let me give you a list of "fair market prices". I actually found it to be much more useful in the long run than running any of the formulas. Just look up the product you're interested in and check the fair price for what you need. If it's above that, feel free to make it. Otherwise, be a buyer. That will be the second Appendix.

Overall I hope this is useful to Kapilands players. You certainly don't need to know it. And in fact you might prefer not to have everything figured out like this. In a sense it takes the challenge out. But I hope that those who enjoy numbers and calculations will find that this enables them to supercharge their Kapilands experience.

Knolls

Appendix 1: Values for the Retail Time Formula

Code: Select all

Product			A				B
Apple juice			-67.0645				3369.3806
Apples			8.4032				508.2736
Bananas			9.4434				554.7873
Beds			-396102347.8025				409657286.2152
Beef			78.0272				35708.8254
Beer			-54.3616				2390.3695
Biscuits			-468.4975				1179.9419
Breads			-34.6468				2479.2404
Bottled cocoa			-75.6927				3251.8352
Candy bars			-357.8846				2870.1794
Candy			-849.2278				348.7084
Cars			3206980965463980.0000				28303968153501.0000
Chairs			64025952.4386				38205613.2006
Chickens			208.6261				17072.8620
Cocoa powder			-285.1145				740.9402
Coffee powder			-1513.6719				1186.3407
Computers			1315296734.7565				1317207347.9135
Cabriolets			2038328779499870.0000				30262153571131.3000
Detergents			2181.0402				138528.2195
Diamond rings			264721450617.4350				20280875119.9549
Eggs			9.1362				129.9728
Flour			-619.3405				534.5184
Gas			1053.0685				45596.5893
Golden necklaces			91302001980.2578				14677407552.1474
Golden watches			217906056723.8700				13741733745.1362
Grapes			44.9585				478.1563
Jeans			-2656550.3934				16490836.4457
Kapi Cola			126.9975				1713.0266
Lamb			-657.7612				3751.4229
Leather gloves			-1047719.1138				13599820.2388
Leather jackets			202551469.0486				202874061.1979
Lemons			11.1429				565.5334
Lotions			-32476.8127				195607.9847
Milk			17.4222				177.7777
Mincemeat			368.6051				47614.9159
Monitors			61964083.2556				244055161.6784
Motorbikes			25382034479809.7000				1069871523799.0400
Orange juice			291.0626				1720.1645
Oranges			12.6909				468.4448
Pears			23.0863				461.5706
Perfumes			29842.7092				1546024.0877
Pork			-2801.6675				51145.2776
Potatoes			11.5609				687.8485
Printers			46710209.6329				21625611.1818
Pullovers			5584427.8342				6525470.9111
Sausages			-266.6568				1716.3984
Shampoo			-1984.1886				107786.6848
Shoes			-4245490.8489				957263.5293
Silver necklaces			14733921716.8759				347102079.3356
Strawberries			9.9850				565.7183
Stuffed animals			-2967945.0391				169356.7431
Sugar			-3531.9060				1303.3729
Tables			-3977916.1591				53545138.6208
Televisions			267148542.2262				1097702497.5530
Toothpastes			1719.5297				106911.3884
Toys			-7668662.0145				431924.4644
Tires			15252714.5208				2737521.2587
Wardrobes			572726227.6901				3513726066.5850
Wine			4886.2278				110581.2582
Wooden toys			-1685238.6986				345121.4469
Wool			-0.4908				26.1834
Appendix 2: "Fair Market Price" for any product.

Code: Select all

Product	Fair Price
Advertisements	 $396.00 
Apple juice	 $12.59 
Apples	 $1.02 
Bananas	 $1.02 
Beds	 $688.95 
Beef	 $14.57 
Beer	 $15.43 
Biscuits	 $2.15 
Breads	 $4.70 
CPU	 $180.37 
Bottled cocoa	 $6.06 
Cocoa	 $1.48 
Candy bars	 $11.37 
Candy	 $15.00 
Car bodies	 $16,926.45 
Cars	 $64,636.62 
Cattle	 $70.38 
Chairs	 $361.45 
Chemicals	 $3.18 
Chickens	 $7.33 
Coal	 $1.42 
Cocoa powder	 $12.80 
Coffee beans	 $3.00 
Coffee powder	 $16.91 
Computers	 $774.22 
Cabriolets	 $59,750.47 
Corn	 $1.06 
Cotton	 $2.04 
Detergents	 $12.48 
Diamond rings	 $3,501.07 
Diamonds	 $102.00 
E-Components	 $69.82 
Eggs	 $0.78 
Engines	 $6,107.53 
Flour	 $14.20 
Gas	 $4.86 
Glass	 $15.58 
Golden necklaces	 $2,936.16 
Golden watches	 $3,910.75 
Gold	 $79.56 
Grapes	 $1.86 
Iron ore	 $1.63 
Jeans	 $169.66 
Kapi Cola	 $9.69 
Lamb	 $13.29 
Lambs	 $59.78 
Leather gloves	 $81.86 
Leather jackets	 $235.86 
Leather	 $94.43 
Lemons	 $1.02 
Lotions	 $10.24 
Milk	 $0.33 
Mincemeat	 $14.14 
Minerals	 $1.60 
Monitors	 $290.18 
Motorbikes	 $14,368.74 
Oil	 $18.00 
Orange juice	 $12.59 
Oranges	 $1.02 
Pears	 $1.02 
Perfumes	 $36.46 
Pigs	 $70.38 
Plastic	 $27.21 
Pork	 $10.97 
Potatoes	 $0.70 
Power	 $0.06 
Printers	 $260.68 
Pullovers	 $62.81 
Quartz	 $1.62 
Rubber	 $7.39 
Sausages	 $11.62 
Seeds	 $0.10 
Shampoo	 $13.06 
Shoes	 $139.61 
Silicon	 $5.90 
Silver necklaces	 $2,109.60 
Silver	 $68.04 
Steel	 $46.72 
Stones	 $2.60 
Strawberries	 $1.02 
Stuffed animals	 $159.65 
Sugar cane	 $4.48 
Sugar	 $17.76 
Tables	 $196.81 
Televisions	 $455.09 
Textiles	 $36.13 
Toothpastes	 $5.45 
Toys	 $190.02 
Wardrobes	 $794.27 
Water	 $0.07 
Tires	 $339.72 
Wine	 $58.30 
Wood	 $18.72 
Wooden toys	 $178.62 
Wool	 $1.48 

Last edited by Guest on 06.04.2009, 22:09, edited 1 time in total.

Guest

Post by Guest » 04.04.2009, 09:10

nice post here knolls

Guest

Post by Guest » 04.04.2009, 12:10

I cannot say enough. :) Every time you see a post by knolls you know to grab a cup of coffee and settle in for a great lesson. :D

Too bad I have to leave for work so soon. I am going to be thinking, instead of playing, with this all day. :wink:

Guest

Post by Guest » 04.04.2009, 16:30

Wonderful :D

Thanks for popping in knolls :)

Guest

Post by Guest » 05.04.2009, 00:43

Thanks Warrior. The other two just like it because I used their names. 8)

Guest

Post by Guest » 05.04.2009, 01:41

Knolls wrote:Thanks Warrior. The other two just like it because I used their names. 8)
Nobody made you use the names... Image

Guest

Post by Guest » 05.04.2009, 06:09

while this is a great way to find out which product gives the best ROI, it does not show which building gives the most profits (please correct me if i'm wrong).

because of this, i compared products using 'profits per 20 sqm per hour'

Guest

Post by Guest » 05.04.2009, 10:18

(Price ^ 3.5 - A) / B = Time in minutes to sell 1 in a 100m store.
Ok now is this price you set in store to the power of 3.5? I didnt check the validity of the 3.5 power behavior, but with your A and B it gives outrageous results. 1 unit of perfume priced at 100 selling for 10 hours in a 100 sqm shop? Jesus christ.

Also the fair market prices seem horribly unfair. Did you use 0.01 for power and water?

Except for that, yes, i agree with Azer, warrior and felixblu. Excellent posting that gives a ltremendous amount of insight which should be taught in every elementary school :roll:

Guest

Post by Guest » 06.04.2009, 13:13

On validity of the power of 3.5 rule: Here are fits on the selling time of q22 wardrobes (selling time in hours per employee). Blue line is simple polynomial fit to the order of 3 while red line is best fit of (selling price^3.5-a)/b

Image

Here is another fit, the polynomial stays the same while the 3.5 one is adjusted to fit better to the 2 extra prices (6k and 7k per wardrobe)
Image

You can see that the 3.5 does (approximately fit at region of 3.3k and again at 6k, but in the area with the optimum price (around 4.9k) it fails miserably compared to the simple polynomial fit (which is simpler to do than the 3.5 fitting imo).

If you want the exact coefficients used in polynomial and 3.5 fit, pm me. Though they will only stay valid untill the stats avg price and quality change. If you want me to make another fit, send me data in form of {{a1,b1},{a2,b2},...} where a1... are selling prices and b1... are selling times in hours. 8)

EDIT: I messed up the units on y axis. Scale them down by approximately a factor of 5 (divide units by 5)
:oops:

Although i have to admit that the 3.5 law comes relatively close to setting the optimal price. In this graph i show the hourly profit per employee calculated using both methods, red is 3.5 law and blue is polynomial.

Image

It is clear that the 3.5 law predicts a bit too high profit, but as far as optimal price is considered, it only misses about 70 caps. Optimal for 3.5 is at 4803 and for polynomial at 4873. Which in terms of hourly profit per employee only misses by 0.3 caps hourly/employee. Which is quite good approximation.

So all in all, its a good enough approximation for the economists.

Guest

Post by Guest » 06.04.2009, 22:07

Picking me apart, huh Greed? :) I used 0.06 for power and water. (Which is still long-run low.)
1 unit of perfume priced at 100 selling for 10 hours in a 100 sqm shop?
Is that what I said? Oops! When I originally measured I used 10 or 100 for most items, just to get better averaged times. And then when I was presenting this, I tried to factor those variables out in my head. But I think I did it backwards and as such the B column was off by a couple orders of magnitude.

Sorry!

Updating the numbers now. Try again and you should get something like 6.4 minutes for 1 perfume at 100.

Guest

Post by Guest » 06.04.2009, 23:45

Great knolls. :D
I understand about half of it, but it looks interesting.
Now.. could anyone explain this the Kiddily winky way please?:shock:
Felix?..
Just for those of us who want to put it into practice but don't neccesarily understand the whole explanation.
The formula for instance:
(Price ^ 3.5 - A) / B = Time in minutes to sell 1 in a 100m store.

Questions:
-What does ^ mean?
-So, you first calculate price ^3.5 minus A, and the outcome of that you divide by B.
Then you get the time it takes to sell one product.
-A and B are to be found on the list below.
Do I understand this right so far?
-And this is for a 100m2 store, so what if you want to calculate a 1000m2 store?

Another thing, I remember a while ago I posted something about putting 1 to 20 products in my shop and it took 10 minutes, whether it was one or 20 products it stayed 10 minutes.
Over 20 (or it could also be 19 I don't remember) the selling time increased.
How does this go with the formula?

It might seem like dumb questions to some of you but I can imagine their might be people who don't understand this stuff and it is a shame if those people are put of just because they think it will be to complicated for them.

Guest

Post by Guest » 07.04.2009, 02:55

This is pretty high-level, more than what I usually write. But you understand it correctly.

^ is a power. Price^2 would Price Squared, or Price x Price. Price^3 is cubed.

So the 3.5 power seems a little weird, but most calculators can handle it.

Example: Beer, price 30

Time = (30 ^ 3.5 - 54.3616) / 2390.3695
= (147885.0905 - 54.3616) / 2390.3695
= 147830.72 / 2390.3695
= 61.84 minutes
or just over an hour. (Hopefully that checks out in game.)

And yes there is a minimum selling time so this applies best to larger sales with more items.

Guest

Post by Guest » 07.04.2009, 09:37

sally wrote: -And this is for a 100m2 store, so what if you want to calculate a 1000m2 store?

Another thing, I remember a while ago I posted something about putting 1 to 20 products in my shop and it took 10 minutes, whether it was one or 20 products it stayed 10 minutes.
Over 20 (or it could also be 19 I don't remember) the selling time increased.
How does this go with the formula?
If you want to calculate a 1000 sqm store just divide the selling time by 10 (because it has 10 times more employees), if you had an arbitrarily big building, its best to calculate selling time per employee and divide it by number of employees you have in the arbitrary building.

Example: 20k rubber toys for ladies sell at 999 caps for 44355 hours and 36 minutes in a 100 sqm shop (10 employees). This means that 10 sqm shop (one employee) would sell them in 443556 hours. (note that 44355hours and 36 minutes = 443556 hours / 10 {number of employees in 100 sqm shop}).
So now if you have a store of 6660 sqm (666 employees), you divide 443556 hours of selling time per employee with number of employees, that is 666. So now 443556/666 = 666. Meaning 20k rubber toys for ladies would sell in 666 hours at price of 999 in a shop with 666 employees.

Now for the 10min. 10min is the lowest selling time in shop (to avoid someone mispricing and selling all in 1 second or something equally short. So if you sell for example one latex dress in a store in germany with 3200 employees at 10 caps, which would in modern germany be sold in less than minute, in kapilands it takes 10min.

Hope this helped
8)

Guest

Post by Guest » 07.04.2009, 14:02

:lol: :lol:
I can't think of a witty reply without incriminating myself so I won't. :shock: :wink:
But I get your point(s).
And yes it helps.
Thanks a lot Knolls and Greed. :D :D
Last edited by Guest on 07.04.2009, 14:17, edited 1 time in total.

Guest

Post by Guest » 07.04.2009, 14:17

I don't understand half of this so *smile and nod*

Post Reply