This will probably turn out to be one of those things that everybody except me already knew, so I know I am setting myself up for a fall here.
I only noticed today when I was trying to enter a really long number. Excel records the first fifteen digits and replaces everything after than with zeroes. For sure, it was my Tesco Clubcard number, so I could save it as text, but that's not the point. It's an up to date version of Excel, by the way.
Ho hum.
Saturday, 26 December 2020
Shock horror - Excel only stores numbers to fifteen significant figures
Posted by
Mark Wadsworth
at
16:44
14
comments
Labels: Excel
Saturday, 8 February 2014
Excel is really good for page layout and photo collages
Inserting pictures and logos into a Word document is usually a right old faff, because they keep disappearing off the page, resizing themselves and re-formatting themselves.
I had to help my little girl put five photos on a page for her geography homework project, we downloaded five suitable ones from the Internet and did a nice layout using Excel in the space of five minutes; we set all column widths and row heights to one centimetre as a guide, and used the cells beneath the photos to type in the captions.
Result!
Here's a screenshot, the gridlines don't print off:
Posted by
Mark Wadsworth
at
13:50
8
comments
Monday, 19 August 2013
Fun with functions: who's afraid of the big bad nequity?
1. One of the excuses which The Powers That Be use to prop up house prices is "the spectre of negative equity", which they know did for the Tories after 1992.
2. Now, as we remember from our lessons in finance, there is a fixed mathematical relationship between four variables: the principal amount of a loan, the term, the interest rate and the annual capital and interest payments required to pay it off. And these calculations are exactly the same for annuities (i.e. what you are supposed to spend your pension pot on). So if you know three of these variables, you can can calculate the missing one.
3. It is not very pleasant having a mortgage which is bigger than the value of your home but this is purely psychological.
4. The annual repayments have to be paid out of your annual income, not out of the value of the house - a mortgage doesn't automatically cost you more just because you are in nequity (glossing over the fact that the banks will bump up the interest rate). And banks don't like negative equity either, as only part of the loan counts as "secured", even though ultimately, loans are only secured on their borrowers' future earnings.
5. So what "the government" could do is allow house prices to fall by (say) a quarter and take any nequity-tainted mortgages off the banks' books. Borrowers are given a smaller replacement mortgage equal to the value of the house, and banks are given new government bonds with a nominal value equal to the existing principal (they do not have to recognise losses because there aren't any).
6. This need not be a get-out-of-jail-free card for borrowers... because the government can set the interest rate on the new loans slightly higher, so that the annual repayments (receipts, from the government's point of view) over the rest of the mortgage term are the same as they would have been at the old lower rate.
7. And the government could make a small mark-up on the deal as well. The interest rate which it has to pay (or which banks will demand) on government bonds is (say) 1% lower than the interest rate which normal borrowers were paying (because of better credit risk), and it can pool all these mark-ups to cover it against any actual losses incurred.
8. Here's the spreadsheet for you to muck about with. You can change the figures in the yellow boxes, the rest is functions (PMT and RATE).
Posted by
Mark Wadsworth
at
11:32
13
comments
Labels: Excel, Finance, Interest rates, Nequity
Thursday, 28 June 2012
British Banking Association's figures don't seem to add up
There were a few headlines yesterday reporting that the BBA had said that "mortgage lending was falling for the first time since 1997" or similar, which were all suitably vague as to whether they meant monthly lending or total mortgages outstanding.
It turns out that they mean the latter, i.e. last month, repayments exceeded new loans, their blurb is here, what is interesting is the accompanying spreadsheet, Excel.
1. I've bunged the figures for total outstanding (Tab 5, nsa) into a chart, that looks to me as if the total started falling in about May 2008, which is what you'd expect because that is when the 'financial crisis' first hit.

2. It also shows that the total skyrocketed after that, which they explain thusly:
"Following a change in the reporting of covered bonds from April 2009, the mortgage assets, held within such special purpose vehicles, have been added back into their parent banks' reported mortgage lending. These movements have been adjusted out of flows."
In other words, matching assets/liabilities which they had shifted off their balance sheets were shifted back on again. This indicates that about a fifth of mortgages had been bundled into SPVs and the like.
But when it boils down to it, you can add together the £768 billion residential mortgage lending, plus a quarter for commercial, plus a modest £35 billion for unsecured consumer lending (i.e. credit cards and the like) plus a few other bits and pieces, and you end up with a tad more than £1 trillion. This is the true measure of UK banks' assets/liabilities, about two-thirds of GDP.
Their interest margin (i.e. their monopoly rent income) is 2% or so, so by and large, we'd expect bank income net of interest to be a bit less than 2% of GDP. The notion put about by politicians during the bubble years and even today that "the City of London contributes" (or indeed "steals", from my point of view) ten per cent of GDP is infantile.
You often read that UK bank assets/liabilities are five time UK GDP, or ten times, or whatever, but they are not. The rest of it is fluff, double entry bookkeeping, inter-bank lending (which adds not a penny to banks' total assets or liabilities on a consolidated basis) and so on. It's like a little hedgehog putting up its spikes to look scary.
3. What's also irritating is that the columns don't add across. Surely, if gross loans in April were £6,414 bn and repayments were £7,095, then total lending went down by £681 billion, not £543 billion?
Posted by
Mark Wadsworth
at
17:59
3
comments
Labels: Accounting, Banking, Council of Mortgage Lenders, Excel
Tuesday, 19 June 2012
"Buying beats renting by almost £200,000 over lifetime"
Here's the original Barclays press release which has been re-hashed by most newspapers over the past two days:
Stepping onto the property ladder has enormous financial benefits over a person's adult lifetime. According to a new study from Barclays, owning your home rather than renting it will save you £194,000 over a fifty year period. And this figure doesn't even account for the value of the home the buyer will own at the end of it.
While the total cost of mortgage repayments, maintenance, and other costs associated with owning the average home would come to £429,000 over fifty years (a person's adult lifetime since a typical buyer purchases in his early thirties) renting a similar home over the same period would cost £623,000. Recognising that getting on the housing ladder, or trading up is still a substantial barrier to many, Barclays has created a new mortgage scheme (Helpful Start) which has a Family Affordability Plan incorporated into it, that lets parents help their children with loan affordability...
"Well, they would say that, wouldn't they?" you might think, but at least they explain why:
Over a fifty year span, roughly 50 per cent of the cost of occupying your own home comes in the form of mortgage payments - £210,000 out of the £429,000. Two fifths of that £210,000 is interest cost, while the rest is capital repayment. The next largest outlay is maintenance at £170,000. The initial purchase deposit is the next biggest cost, while insurance, stamp duty and other costs associated with buying the house in the first place make up the rest.
Yup, you "save" £194,000 and the bank earns £84,000 interest, of which it pays half to depositors and the rest is pure profit. Fag packet says £129,000 x 2% margin (rent) x 25 years, minus a third because mortgages are reducing balance = £43,000.
Only the "saving" is nowhere near what they claim, is it? They explain their assumptions (rents rise by 2% inflation and the tenant earns interest on the money he would have used as a deposit etc) and the total figure of £623,000 spent over the next fifty years looks about right - but they do not then discount this figure backwards to give the net present value. If you discount these payments backwards at Barclays' assumed savings rate net of tax (for want of a better discount rate), the total cost of renting in today's money is £310,000 and the total cost of buying is £277,000.
In relative terms, buying is more expensive because payments are front loaded, at a time when you might have other things to spend money on, like having children etc. For completeness; if you use a higher discount rate of 3.8%, the cash cost is exactly the same for renting and buying.
So there's not that much difference in the cash cost, the difference is that you will (hopefully) end up with a mortgage-free house*, the value of which will almost certainly have gone up faster than inflation and probably faster than wages. But I see no great urgency to "step onto the property ladder".
* Or maybe not.
Posted by
Mark Wadsworth
at
10:28
13
comments
Labels: Banking, Barclays, Excel, Mortgages, Propaganda, Rents
Saturday, 31 March 2012
Calculating pi = 4/1 - 4/3 + 4/5 ...
There's a mildly interesting series on BBC4 at the moment called The Story of Maths, which is unfortunately more about history than maths (and an excuse to take a few expenses paid holidays around the world), in which the presenter explained how somebody had worked out that you could calculate pi by taking 4/1, subtracting 4/3, adding 4/5, subtracting 4/7 and so on.
All I can say is, although it was clearly an insight of blinding genius to realise this, they must have been really bored after that, as it takes you a heck of a long time to get anywhere near pi in this manner.
The first chart showing the results for the first 20 iterations looks very promising, but it strikes me that after about 40 iterations (second chart), somebody will have said "Sod this for a game of soldiers, let's take an average of the last few results and call it a day." Even if they'd slogged their way up to 100 iterations (third chart) or up to 1,000 iterations (bottom chart), they wouldn't have got much closer than by just averaging the 39th and 40th results:



Posted by
Mark Wadsworth
at
14:47
12
comments
Labels: Excel, Maths, Television
Friday, 23 March 2012
"HM Revenue & Customs: The Exchequer effect of the 50 per cent additional rate of income tax"
I've reverse engineered the calculations they made in explaining why cutting the 50p top income tax rate to 45p would probably be revenue-neutral (see their calculations and explanations on page 15 and the chart on page 51) and I've embedded the key part of the spreadsheet below for your entertainment.
Their aim seems to be to set the income tax rate at the revenue-maximising rate, there are a few of problems with this:
1. They accept 12.8% Employer's NIC and 1% Employee's NIC as a given, even though these have both increased by 1% and are just another layer of income tax.
2. They cheerfully admit that they have no idea what the elasticity of supply of labour is (which they refine slightly and refer to as 'Taxable Income Elasticity' or TIE). On pages 18 and 19 they summarise lots of studies from various countries which give figures between 0.2 (people continue working and paying tax, even if wages fall and/or tax rates increase) and 0.8 (people will work less, avoid or evade taxes, move abroad etc if wages fall and/or tax rates increase), ignoring outliers. They can't make up their minds whether to use 0.35, 0.45 or 0.55 (so their chart uses all three).
3. As the calculations show, this is the most important unknown of all; if you assume a low sensitivity of 0.2, then the revenue-maximising income tax rate (i.e. the top of the Laffer curve) is 67%, and if you assume a high sensitivity of 0.8 it's 35%. Of course, different people respond differently; the rate might be different for high earners and low earners; the short term responsiveness might be more or less than long term etc.
4. They say that TIE can be split up into three things: labour supply (people work less or move abroad), tax planning (people work just as much but use legal loopholes) and evasion (people work just as much but do it cash-in-hand), and say the labour supply effect is "between one-third and one-half of the total TIE". This is their roundabout way of admitting that taxes on income have dead weight costs.
5. Those dead weight costs are also an incredibly important consideration. My spreadsheet shows the fall in potential GDP in the last row, i.e. the fall in declared taxable income multiplied by 0.4, which seems to come out at between 10% and 15%. That's a heck of a lot of lost output and unnecessary unemployment, by the way.
The figure for total revenues assumes that GDP starts at 100, with a flat income tax rate of 10% and National Insurance still in place (even these low rates must depress GDP by five per cent or so, let's gloss over that).
6. Another thing they ought to consider is that the cost of welfare is just an upside down Laffer curve; the way to minimise the cost of means-tested benefits is to find out what the revenue-maximising tax rate on lower earners with a small independent income would be and then to use that as the marginal withdrawal rate.
As a matter of fact, marginal withdrawal rates (especially for people who have tax deducted and benefits withdrawn at the same time) are between 70% and 100%, which is way beyond the top of the Laffer curve - in other words, we could reduce the cost of means-tested welfare by reducing income-based means-testing, although that point seems to escape them.
Posted by
Mark Wadsworth
at
22:27
2
comments
Labels: Excel, Income Tax, Laffer, Maths, Welfare reform
Wednesday, 29 February 2012
Design your own LVT system
You can change the figures in the boxes and enter your own by clicking "Click to edit". The grey cells are results/output cells.
Posted by
Mark Wadsworth
at
21:15
30
comments
Labels: Excel, Land Value Tax, Taxation
Tuesday, 21 February 2012
Tax/benefits spreadsheet for future reference
For general reference, I have prepared a Zoho Sheet showing how much tax people actually pay under the current tax/benefit system (it's more than you think, because of all the stealth taxes), and just for fun, I tacked on what your tax bills would be if I were in charge. To save arguments, let's assume that pensioners' main residences are exempt from LVT, so the comparative figures do not apply to them.
I'm sure you're all familiar with the current tax/benefits system, so that needs little explanation. I explained my suggested tax system here and my suggested Citizen's Income scheme here.
Posted by
Mark Wadsworth
at
19:21
29
comments
Labels: Citizens Income, Excel, Land Value Tax, Tax Credits, Taxation
Sunday, 30 January 2011
Home-Owner-Ist Myth Of The Week
Bruce trotted out the old mantra here:
This rather assumes all that equity in houses is down to house price rises... But actually some equity is the original deposit and some is what's been paid back in real cash. In times such as these of low/no house price inflation, most or all the equity is made up of the above.
That statement is simply not true, or at best it relates to the exception rather than the rule.
To save adjusting for inflation, I downloaded the inflation adjusted average house prices since 1975 from the Nationwide. I assumed an initial deposit of 20% of the house price and a repayment mortgage over 25 years with an average interest rate of 6% to give us the cash expense side of things.
But those mortgage repayments serve two purposes: they pay off the loan and they provide you with somewhere to live. The average rental income of an average UK house is (say) £8,000 a year (being the average from the RPPI less £3,000 annual 'running costs', i.e. things you wouldn't have to pay if you were a tenant), so as I included total mortgage repayments (including interest) as an expense, I deducted the value of the rental income/the rent you saved by buying not owning.
Thus it appears that there are very few people for whom it is true that "housing equity = deposit + total mortgage payments". In fact, if you bought before the year 2000, the net cash cost of buying a house has been less than zero so far - you'd have been better off buying than renting even if house prices now fell to £nil, so having a lot of 'equity'* is just lots and lots of icing on the cake.
People who bought since 2003 are suffering a loss (they would have been better off renting and saving up the difference between mortgage repayments and rents). Click to enlarge:
* I use the term loosely - this generation's 'equity' is merely the next generation's extra debt burden, it's not real wealth any more than the value of a slave is 'wealth'.
Posted by
Mark Wadsworth
at
17:20
7
comments
Labels: Excel, Home-Owner-Ism, House prices, Propaganda
Wednesday, 26 January 2011
Trade to population, GDP ratios
As I said here, "Of course imports (or exports) as a percentage of GDP are higher in the UK than in the USA or the Eurozone, because their economies are five times as big (five times as many people), but that was on the basis of three random figures* and basic logic.
Just to see whether this stacks up in real life, I have now taken the time and trouble to harvest the relevant figures for GDP, an average of exports/imports (referred to as 'trade') and population from the fine OECD website** and prepared a chart of the trade-to-GDP ratio plotted against population (click to enlarge):
The correlation between trade-to-GDP ratio and the logarithm of the population is 0.60***.
The chart for trade-to-GDP ratio plotted against GDP looks much the same. The correlation between the debt-to-GDP ratio and the logarithm of GDP is also 0.60*** (click to enlarge):
Ah well, at least we know.
* One of which is open to debate as to its accuracy. The UK's and the USA's trade-to-GDP ratios were stated correctly at 32% and 16%, but the figure given by the FT for the Euro-zone was 16% but according to the OECD it's 41%. I suspect that the OECD merely added together country figures without netting off intra-Euro-zone trade. Twats.
** I used figures from 2008 for consistency, choosing GDP and import/export figures expressed in terms of USD/purchasing power parity/current prices. Luxembourg, with a population of less than half a million has a trade-to-GDP ratio of 161%, which is completely off the scale, probably exaggerated by all the cross-border trades routed through it for tax reasons, so I excluded that otherwise tip-top country.
*** I decided to chuck out the figures for the Euro-zone and recalculate the correlation of the trade-to-GDP ratio with the logarithm of GDP or population, which is 0.60 in each case. The correlation with the actual GDP or population is only 0.37 and 0.27, i.e. much lower, which were the figures I gave originally.
Posted by
Mark Wadsworth
at
21:57
9
comments
Labels: Excel, GDP, OECD, Population, statistics
Thursday, 30 December 2010
Awesome spreadsheet
The DWP have changed the format of their (most useful) Tax Benefit Model Tables. Instead of just showing the results, they now publish the spreadsheet so that you can see the underlying formula (and bodge them to your heart's content).
My favourite is the formula for calculating Housing Benefit:
=IF(Rent30-HBtaper*MAX(MAX(F37+G37+H37-IF(Adults=1,IF(chn=0, IF(WTCamt30>0, Rates!$F$58+Rates!$F$61, Rates!$F$58), IF(WTCamt30>0, Rates!$F$60+Rates!$F$61, Rates!$F$60)), IF(WTCamt30>0, Rates!$F$59+Rates!$F$61, Rates!$F$59))-IF(Chcost>0, IF(chn>0,MIN(Chcost, IF(chn=1,175,300)),0),0),0)-HBapp30,0)
But the most important figure is the 'replacement ratio':
Replacement Ratios are the net income after housing costs if out of work and reliant upon benefits as a percentage of net income after housing costs when the head of the family is in full-time work. A replacement ratio of less than 100 per cent indicates that the family has a higher net income when the head of the family is in work than if unemployed and in receipt of benefits.
The replacement ratio for a family with Dad, Mum and two kids (assuming that one parent is working at least 30 hours a week, i.e. using the 30-hour Table) starts at 79% and doesn't drop to 50% until the working parent is earning £938 a week (nearly double the UK average wage).
At that level of gross wages, the family's net income (£482) is double what it would be were they just on benefits (£241), so it still woefully understates the average marginal tax/benefit withdrawal rate - even though the working parent earns £938 a week gross, the family is only £241 better off, which is a marginal tax/benefit withdrawal rate of 74%.
And remember that this rate does not include Employer's National Insurance or VAT (which add 'about' twenty per cent to the true tax rate), so when I generalise and say that people in the UK have an average tax rate of 50%, it's just as likely that I am understating as overstating the real horror of all this.
Posted by
Mark Wadsworth
at
17:56
10
comments
Labels: DWP, Excel, Maths, Welfare reform
Saturday, 22 May 2010
More Labour Leadership/Venn Diagram Fun
In case my previous efforts were not quite puerile enough, here's another one:
Posted by
Mark Wadsworth
at
19:17
3
comments
Labels: Ed Balls MP, Excel, Labour, Yvette Cooper
Quick guide to Labour leadership election
Posted by
Mark Wadsworth
at
10:23
10
comments
Labels: David Miliband MP, Diane Abbott, Ed Balls MP, Ed Miliband, Excel, Labour


