How to create size-rotating-file handler in JBoss 7.2 using CLI

There are times when we require a size-rotating-file handler over the default periodic-rotating-file handler. Simply changing the properties in standalone.xml won't do because it will cause synch problem with logging.properties. So to do so we need to execute a series of JBoss cli commands.

First you need to run: jboss_home/standalone/bin/jboss-cli.sh and connect.


//remove the default file handler
/subsystem=logging/periodic-rotating-file-handler=FILE:remove

//create the new file handler
/subsystem=logging/size-rotating-file-handler=FILE:add(file={"path"=>"server.log", "relative-to"=>"jboss.server.log.dir"})
/subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="autoflush", value="true")
/subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="level", value="WARN")
/subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="append", value="true")
/subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="max-backup-index", value="10")
/subsystem=logging/size-rotating-file-handler=FILE:write-attribute(name="rotate-size", value="5000k")

References:
https://access.redhat.com/site/documentation/en-US/JBoss_Enterprise_Application_Platform/6/html/Administration_and_Configuration_Guide/Configure_a_Periodic_Log_Handler_in_the_CLI1.html
https://access.redhat.com/site/documentation/en-US/JBoss_Enterprise_Application_Platform/6/html/Administration_and_Configuration_Guide/Sample_XML_Configuration_for_a_Size_Log_Handler.html

What is the OLG model of money good for?

I want to say a few things in response to Brad DeLong's post concerning the usefulness of overlapping generations (OLG) models of money (and on the value of "microfoundations" in general). Let's start with this:
As I say over and over again, forcing your model to have microfoundations when they are the wrong microfoundations is not a progressive but rather a degenerative research program.
Why is he saying this "over and over again" and to whom is he saying it? What if I had said "As I say over and over again, forcing your model to have hand-waving foundations when they are the wrong hand-waving foundations is not a progressive but rather degenerative research program."? That would be silly. And the quoted passage above is just as silly.

A theory usually take the following form: given X, let me explain to you why Y is likely to happen. The "explanation" is something that links X (exogenous variables) to Y (endogenous variables). This link can be represented abstractly as a mapping Y = f(X).

There are many different ways to construct the mapping f. One way is empirical: maybe you have data on X and Y, and you want to estimate f. Another way is to just "wave your hands" and talk informally about the origins and properties of f. Alternatively, you might want to derive f based on a set of assumed behavioral relations. Or, you may want to deduce the properties of f based on a particular algorithm (individual optimization and some equilibrium concept -- the current notion of "microfoundations"). Some brave souls, like my colleague Arthur Robson, try to go even deeper--seeking the biological foundations for preferences, for example.

I don't think we (as a profession) should be religiously wedded to any one methodological approach. Which way to go often depends on the question being asked. Or perhaps a particular method is "forced" because we want to see how far it can be pushed (the outcome is uncertain -- this is the nature of research, after all). And I'm not sure what it means to have the "wrong" microfoundations. (Is it OK to have the wrong "macrofoundations?") Any explanation, whether expressed verbally or mathematically, is based on assumption and abstraction. Something "wrong" can always be found in any approach -- but this is hardly worth saying--let alone saying "over and over again."

Now on to the OLG model of money. Here is DeLong again:
Yes, it seemed to me that handwaving was not good. But saying something precise and false–that we held money because it was the only store of value in a life-cycle context, and intergenerational trade was really important–seemed to me to be vastly inferior to saying something handwavey but true–that holding money allows us to transact not just with those we trust to make good on their vowels but with those whom we do not so trust, and that as a result we can have a very fine-grained and hence very productive division of labor.
Not many people know this, but the OLG model (invented first by Allais, not Samuelson) is just an infinite-horizon version of Wicksell's triangle. The following diagram depicts a dynamic version of the triangle. Adam wants to eat in the morning, but can only produce food at night. Betty wants to eat in the afternoon, but can only produce food in the morning. Charlie wants to eat at night, but can only produce food in the afternoon (assume food is nonstorable).


In the model economy above, there are no bilateral gains to trade (if we were to pair any two individuals, they would not trade). Sometimes this is called a "complete lack of coincidence of wants." There are, however, multilateral gains to trade: everyone would be made better off by producing when they can, and eating when they want to (from each according to their ability, to each according to their need).

Consider an N-period version of the triangle above. Adam still wants bread in period 1, but can only produce bread in period N. Now send N to infinity and interpret Adam as the "initial old" generation (they can only produce bread off into the infinite future). Interpret Betty as the initial young generation (they produce output in period 1, but want to consume in period 2), and so on. Voila: we have the OLG model.

I've always considered Wicksell's triangle a useful starting point for thinking about what might motivate monetary trade (sequential spot market trade involving a swap of goods for an object that circulates widely as an exchange medium). In particular, while there is an absence of coincidence of wants, we can plainly see how this does not matter if people trust each other (a point that DeLong alludes to in the quoted passage above). If trust is lacking--assume, for example, that only Adam is trustworthy--then Adam's IOU (a claim against period N output) can serve as a monetary instrument, permitting intertemporal trade even when trust is in short supply.

An exchange medium is valued in an OLG model for precisely the same reason it is in the Wicksell model or, for that matter, any other model that features a limited commitment friction. So if anyone tries to tell you that the OLG model of money relies on money being the only store of value to facilitate intergenerational trade, you now know they are wrong. The overlapping generation language is metaphorical.

In any case, as it turns out, the foundation of monetary exchange relies on something more than just a lack of trust. A lack of trust is necessary, but not sufficient. As Narayana Kocherlakota has shown (building on the work of Joe Ostroy and Robert Townsend) a lack of record-keeping is also necessary to motivate monetary exchange (since otherwise, credit histories with the threat of punishment for default can support credit exchange even when people do not trust each other).

Also, as I explain here, a lack of coincidence of wants seems neither necessary or sufficient to explain monetary exchange. (Yes, I construct a model where money is necessary even when there are bilateral gains to trade.)

Are any of these results interesting or useful? Well, I find them interesting. And I think the foundations upon which these results are based may prove useful in a variety of contexts. We very often find that policy prescriptions depend on the details. On the other hand, I have nothing against models that simply assume a demand for money. These are models that are designed to address a different set of questions. Sometimes the answers to these questions are sensitive to the assumed microstructure and sometimes they are not. We can't really know beforehand. That's why it's called research.

Finally, is a "rigorous microfoundation" like an OLG (Wicksell) model really necessary to deduce and understand the points made above? I suppose that the answer is no. But then, it's also true that motor vehicles are not necessary for transport. It's just that using them let's you get there a lot faster and more reliably.

The most obvious source of cyclical asymmetry is not a nominal rigidity

I've long been interested in the apparent cyclical asymmetry in business fluctuations. So it's nice to see Paul Krugman publicize the issue here: On the Asymmetry of Booms and Slumps. His post, in turn, was motivated this one, by Antonio Fatas: Four Missing Ingredients in Macroeconomic Models. Fatas writes:
1. The business cycle is not symmetric. Most macroeconomic models start with the idea that fluctuations are caused by a succession of events that are both positive and negative (on average they are equal to zero). Not only this is a wrong representation of economic shocks but it also leads to the perception that stabilization policy cannot do much. Interestingly, it was Milton Friedman who put forward the "plucking" model of business cycles as an alternative to the notion that fluctuations are symmetric. In Friedman's model output can only be below potential or maximum. If we were to rely on asymmetric models of the business cycle, our views on potential output and the natural rate of unemployment would be radically different. We would not be rewriting history to claim that in 2007 GDP was above potential in most OECD economies and we would not be arguing that the natural unemployment rate in Souther Europe is very close to its actual.
Let me dissect the passage above.

1. "The business cycle is not symmetric." Agreed.
2. "Most macro models assume a symmetric impulse mechanism." Agreed.
3. "Not only is this a wrong representations of economic shocks..."

Not sure what to make of this claim. I think it's sensible to assume that the shocks are symmetric (unless there is compelling evidence to suggest otherwise). The asymmetry in question is more likely to be the byproduct of human interaction -- the economy's propagation mechanism.

4. "...but it also leads to the perception that stabilization policy cannot do much."

I'm also not sure what to make of this statement. Economists know that we cannot make any inferences about the desirability of policy interventions solely on the basis of the statistical properties of time-series data. And in any case, there are plenty of symmetric models suggesting beneficial policy interventions.

5. "If we were to rely on asymmetric models of the business cycle, our views on potential output and the NRU would be radically different."

I'm afraid that Fatas is placing the cart before the horse here. There is no logical basis for that proposition (in fact, I provide a counterexample below): see comment above.

6. "We would not be rewriting history to claim that in 2007 GDP was above potential..."

I hear people make this claim all the time. Typically, they are the same people who claim that the last recession was caused by a bursting asset-price bubble -- of an overheated real estate sector -- of a booming construction (and related) sectors--of over-accumulated capital--and over-accumulated debt. But now, apparently, these same people want to interpret the episode leading up to the crash as the economy just humming along at "potential." Strange.

In any case, on to Krugman's pet idea that asymmetry is explained by DNWR (downward nominal wage rigidity). Maybe there's something to this idea, but my own view is that any such effect is not likely to be very important. Why is this?

I've explained why before here, but let me summarize the argument here. I claim that economists who rely on sticky wage theories are unwitting slaves of Marshall's scissors--static supply and demand curves. If unemployment exists, it must be because reality does not correspond with scissor-intersection: markets do not clear.

But Marshall's scissors are meant to describe what happens in an anonymous spot market for goods like wheat or oil. The labor market is a market for relationships. Relationships are durable. Relationships are a form of capital. We have to move away from Marshall's scissors to understand these relationships (search theory is one way to do this). The economic surplus generated by a productive relationship is divided through a bilateral or multilateral bargaining process that specifies (among other things) how wages are to evolve through time over the life of the relationship. The spot wage (the wage that an econometrician might observe in a data set) plays no allocative role in the relationship. Stickiness in the spot wage does not matter.

That's the theory, anyway. But then, there is also some evidence: Evaluating the Economic Significance of Downward Nominal Wage Rigidity (Michael Elsby) and here: The Effect of Implicit Contracts on the Movement of Wages over the Business Cycle (Beaudry and DiNardo).

Well then, if not a nominal rigidity, what might account for the asymmetry in the unemployment rate?


As it turns out, the sharp rise in unemployment followed by a slow decline follows as a natural property of labor market search models, something that I showed here (the example I alluded to above).

The basic idea is very simple. As I explained above, the labor market is a market for productive relationships. It takes time to build up relationship capital. It takes no time at all to destroy relationship capital. (It takes time to build a nice sandcastle, but an instant for some jerk to kick it down.)

We see the same sort of phenomenon in population dynamics--the so-called "heat wave effect." That is, mortality rates spike up during a spell of bad weather, causing a sudden decline in the population. There is no corresponding spike up in the population during a spell of good weather for obvious reasons (unless you believe in zombies returning suddenly to life).

***

PS. Some related papers where a shock destroys (reshuffles) match capital and takes time to recover: Adaptive Capital, Information Depreciation, and Schumpeterian Growth (Jones and Newman) and Distributional Dynamics Following a Technological Revolution (Andolfatto and Smith). 

In gold we trust?

I've written before that a desirable property of a monetary instrument is for it to hold its value over short periods of time (See: Why Gold and Bitcoin Make Lousy Money).

In other words, a good monetary instrument should have a stable short-run rate of return. If I earn some money today, I don't want to see its value decline by 50% tomorrow. If I spend a dollar today, I don't want to see its value rise by 50% tomorrow. Even if these fluctuations cancelled out in the long run, it would be terribly inconvenient and annoying. I'd rather live in a world where my money lost value at a slow but steady rate. Of course, I would not want to store my wealth in the form of such an instrument. But that's not how we store wealth anyway. To store wealth, we can always sell the money we do not need for transaction purposes and purchase other securities.

Now let's take a look at some data -- the type of data Ron Paul likes to use. Let p(t) denote the price-level at date t (I will use the consumer price index). Then 1/p(t) measures the purchasing power of money. If p(t) rises over time (inflation), the purchasing power of money falls over time. And so we have this familiar picture:


I've written about this before here: Ron Paul's Money Illusion.

Now, we can perform the same sort of exercise for gold. Let q(t) denote the USD price of gold at date t. Then the purchasing power of gold is measured by q(t)/p(t). So, if the price of gold rises as fast as the price level, the purchasing power of gold remains constant. If the former rises faster than the latter, then the purchasing power of gold is rising; and vice-versa.

We know that over very long horizons, the rate of return on gold exceeds that of money. But all this says is that gold is a better store of value than cash over long periods of time. (I discuss here whether gold is a good store of value relative to other assets.). How has the purchasing power of gold held up over the last little while?

Here is the purchasing power of gold vs the USD since the beginning of the year:


OK, so this past year was not a good one for gold. If you had earned your wages in gold at the beginning of the year, that gold would now buy you 25% less bread. That's like a tax. And it was not the Fed doing it to you. In fact, if you had instead held on to your USD over same period of time, you would have experienced a much smaller decline in purchasing power.

What if we look at the past 2 years? Here is the picture:


What we see from the picture above is that the purchasing power of gold held up with that of the USD in 2012, but that its short-run rate of return was more volatile. It's rate of return then fell down a  steep hill in 2013.

Let's go back 3 years now:


Gold can't even beat the rate of return on cash over a three-year horizon? That's pretty sad for a store of value.

The main lesson I take away from this is not that people shouldn't invest in gold. By all means, go ahead and invest in all sorts of stuff, including gold. The main lesson is that commodity prices tend to be highly volatile over short periods of time and that this short-run volatility makes them undesirable as payment instruments. There is a better alternative available, and the United States has it in the form of the Federal Reserve.

Happy 100th birthday, Fed!

And a Merry Christmas to all.

PS. My colleague Christian Zimmermann points me to this potentially interesting paper: The Gold Dilemma by Claude Erb and Campbell Harvey.

Konkurransetilsynet bør si nei

Ica og Norgesgruppen ønsker felles innkjøpssamarbeid, men nå har konkurransetilsynet utsatt vedtaket. Det enkleste hadde vært å si nei med en gang. 

Innkjøpssamarbeidet har isolert sett trolig en positiv effekt for forbrukerne på kort sikt. Mer innkjøpsmakt gir lavere pris til forbruker.

Det er imidlertid en veldig kortsiktig og snever betraktning. Langt viktigere er det at samarbeidet vil gjøre det vanskelig for nye aktører. Det er jo slik at høyere volum gir bedre forhandlingsmakt og lavere priser. På grunn av norsk landbrukspolitikk er eventuelle nykommere helt avhengig av å ha norske leverandører. Dessverre kan ikke en nystartet kjede med 2 prosent markedsandel oppnå priser i nærheten av Ica-Norgesgruppen med 50 prosent av markedet. Nykommere vil være sjanseløse.

Det er liten tvil om at konkurransen i det norske dagligvaremarkedet ikke er spesielt sterkt. Den er sterk nok til at Ica ikke klarer å drive lønnsomt, men marginene kunne vært lavere. Det vil derfor være veldig uheldig om konkurransetilsynet velger å blokkere for fremtidig konkurranse.

Alle andre løsninger er bedre; samarbeid med Coop eller Rema, at Ica forsvinner eller at de kjøpes av annen utenlandsk eier. Det vil gi et marked med mindre forskjeller i markedsandeler og en viss spredning i innkjøpsmakt. Dette kan oppnås ganske enkelt ved at Icas søknad avslås.

Icas forsøk på å skyve distriktene foran seg reiser alvorlige spørsmål ved ledelsens økonomikompetanse. Vi lever i en markedsøkonomi. Dersom Ica legger ned en distriktsbutikk det er behov for, vil en annen dukke opp på samme plass. Konkurransetilsynet har ikke ansvar for Icas aksjonærer og bør derfor heller ikke ta hensyn til dem.

Labor Force Participation Gaps (U.S. vs. Canada)

This post is meant as a complement to my earlier posts: [1] Employment Gaps, [2] Employment Slumps in Canada and the U.S., and [3] U.S. Labor Force on Trend?

In what follows, I report the labor force participation rates (LPRs) for Canada and the U.S., for males and females, and across various age groups (1976-2013). Let's take a look first at  prime-age males and females.
 

To the extent that one can consider the Canadian LPR a measure of a common trend (the Canadian recession being less severe than in the U.S.), one might be able to support the idea of a 1-2ppt LPR "gap" for the U.S. 


The behavior of prime-age females across the two countries appears quite similar up until the mid-to-late 1990s. The divergence since then has been quite remarkable. (Has anyone heard of any explanation for why this might be the case?)

Here we have teen-aged males and females. In both cases, we see big gaps emerging some time around 2000.
 


Next we have young males and females. 



And finally, older males and females:



Any comments or suggested references that speak to these patterns would be appreciated. 

U.S. Labor Force Participation Rate on Trend?

The labor force participation rate (LPR) is defined as the share of the civilian noninstitutionalized that is employed (working) or unemployed (looking for work). In 1970, the U.S. LPR was about 60%. It rose steadily for 30 years, reaching peak of 67.1% in 2000. It has been declining since that time, dropping sharply in the recent recession, and currently sits at around 63%.
 
Question: How much of the recent decline in LPR is due to a bad economy (cyclical factors)? And how much of it might be due to long-term trends associated with changing demographics (structural factors)?

The answer to this question is important for policy because a cyclical interpretation suggests the presence of an undesirable "output gap," whereas a structural interpretation does not.

Christopher Erceg and Andrew Levin have a new paper out which suggests that cyclical factors are responsible (Labor Force Participation and Monetary Policy in the Wake of the Great Recession). Much of their estimate of LPR trend, however, seems to be based on a particular BLS projection. On pages 9-10, they state:
In our view, the labor force projections published by the BLS in November 2007 serve as an invaluable resource in assessing the influence of demographic factors on the subsequent decline in the LFPR. In making such projections, BLS sta¤ consider detailed demographic groups using state-of-the-art statistical procedures in conjunction with micro data from the Current Population Survey (CPS) and various other sources, including interim updates from the U.S. Census Bureau.
But as the following figure demonstrates, BLS projections of trend LPR seem to vary quite a bit over time:

The figure above is drawn from
A Closer Look at the Decline in the Labor Force Participation Rate (Maria Canon, Peter Debbaut, and Marianna Kudlyak). The authors state:
It is tempting to interpret the prerecession projections as reflecting the long-term trend in the LFP rate. However, we observed that the BLS's projections did not necessarily capture the long-term trend; rather, to a substantial degree, they were influenced by the most recent data points. Consequently, this cautions against treating the difference between the actual LFP in 2012 and its BLS projection released in 2007 as entirely due to cyclical factors.
[Note: Erceg and Levin do not rely solely on BLS measures of trend LPR. Much of their empirical work is based on state-level differences in labor market variables.]

It is of some interest to note that this is not the first time policymakers have been interested in the cyclical vs. structural decomposition of LPR. The same questions were being asked nearly a decade ago following a much milder recession (and jobless recovery).

In 2006, economists Stephanie Aaraonson, Bruce Fallick, Andrew Figura, Jonathan Pingle, and William Waacher published this interesting study: The Recent Decline in the Labor Force Participation Rate and Its Implications for Potential Supply.

The authors use a cohort-based model to estimate LPR trend. They state their conclusions as follows:
On balance, the results suggest that most of the decline in the participation rate during and immediately following the 2001 recession was a response to business cycle developments. However, the continued decline in participation in subsequent years and the absence of a significant rebound in 2005 appear to derive from other, more structural factors. Indeed, the participation rate at the end of 2005 was close to our model-based estimate of its longer-run trend level, suggesting that the current state of the labor market is roughly neutral for the participation rate. Finally, projections from the model suggest that many of these structural factors will continue to put downward pressure on the participation rate for some time, so that any future cyclical fluctuations in participation will take place around a declining trend.
The most remarkable picture they produce is, in my view, their Figure 12 (pg. 111):


Their 2006 forecast of the U.S. LPR for 2013 was 63%. Not bad.