Results 1 to 5 of 5

Math Help - How much of a given security to stabilize profit/loss

  1. #1
    Newbie
    Joined
    Feb 2013
    From
    Dover
    Posts
    3

    How much of a given security to stabilize profit/loss

    Hi,
    This is a real world problem. I'm trying to figure out how much to reduce the quantity of a given security in order to maximize the stability of the profit and loss. Essentially I'm trying to hedge out the small, intraday fluctuations and take advantage of the long term tendency of one of the securities to decay.

    So we have security D and security N, both of which are being shorted. Since security D has a higher rate of Decay (D for Decay) or loss over time with respect to security N (N for Normal, or Non-decaying), when it is shorted, the negative difference becomes positive, resulting in a profit.

    But this doesn't really show up (much) at a daily level. Most intraday fluctuation is random. So over a single day we want security D and security N to be running at as non-variant a profit and loss as possible.

    I currently have them running with a tentative ratio of 3.81:
    860 SecurityD @ 11.52 = 9907.2
    500 SecurityN @ 75.50 = 37750

    The reason for the difference is that SecurityD is more volatile.
    It is clear that Security D needs to be reduced in order to stabilize P/L. But how much?
    Here are some data points I collected during the day

    SecurityD, SecurityN, Profit/Loss
    11.38, 75.61, 64.15
    11.41, 75.6, 47.65
    11.33, 75.66, 86.45
    11.31, 75.72, 73.65
    11.3, 75.73, 70.45
    11.23, 75.8, 95.65
    11.27, 75.77, 83.05
    11.23, 75.79, 100.65
    11.34, 75.7, 55.35
    11.37, 75.7, 32.05

    So basically we want to find some X multiplied on the SecurityD position such that P/L variance in the right column is minimized as much as possible.

    The correlation isn't perfect, of course (it's actually about -0.88 according to an analysis I ran on 21 daily data points taken over one month).

    I'm not sure how to approach this. I want to use the actual P/L figures in the account as the basis since this is the closest to financial reality as I can get to perform the calculation.

    Thanks in advance for any input
    Follow Math Help Forum on Facebook and Google+

  2. #2
    MHF Contributor
    Joined
    Sep 2012
    From
    Australia
    Posts
    3,664
    Thanks
    606

    Re: How much of a given security to stabilize profit/loss

    Hey JasonW556.

    The question I have for you is: What is your definition of stability?

    If each unit of a stock is independent from the next then the volatility of the portfolio of those stocks will be linear. The variance of the sum of stocks with variance sigma^2 is n*sigma^2.

    Now with this in mind, you have to decide specifically what your constraints are and what specific mathematical attribute you are trying to find.

    To minimize volatility you have to basically sell off your stock but I'm guessing that you have some kind of criteria for minimization which relates profit to the volatility.

    So I would need to ask you how you calculate your profit and what the asset models you are going to use to get closer to a solution.
    Follow Math Help Forum on Facebook and Google+

  3. #3
    Newbie
    Joined
    Feb 2013
    From
    Dover
    Posts
    3

    Re: How much of a given security to stabilize profit/loss

    Hi,
    Thanks for the response. Usually I find volatility measures wind up looking pretty similar. For example, if you measure the high-low differential over a series of bars, that number will correlate well with the standard deviation. But sticking with what I originally stated, we could look at variance or it's rooted cousin standard deviation(SD).

    What should happen is for the SD to have a minimum at a certain quantity of the hedging agent. This makes intuitive sense if you look at two perfectly inversely correlated securities, (like SH/SPY only -1.00 instead of -0.98). If you hold either all SH (or all SPY) you will have the full volatility of the market. So the SD would be the same as the S&P 500. But say you're holding SH and start adding SPY the SD will gradually diminish until you have equal dollar value quantities of each. At that point the SD would be 0 assuming they were perfectly inversely correlated. At this point your P/L samples taken over the day would all show zero.

    Of course nothing is perfectly correlated in the real world, even such pairs as SPY/SH and DIA/DOG aren't perfect inverses.

    Nor are mine. As mentioned the securities I'm trading are at -0.88 according the sample I took.

    Obviously there would be no point in holding equal dollar quantities of two perfectly inversely correlated securities. As you alluded, the trader would be better off just going to cash. The decay I'm speaking of appears over the span of weeks and months. I'm just trying to flatten out as much intraday fluctuation (noise) as possible.


    Re:
    I would need to ask you how you calculate your profit
    =(860*(SecurityDCost-SecurityDPrice)+500*(SecurityNCost-SecurityNPrice))

    The second term is added because it is negated wrt the first term.

    Hope this addresses your questions
    Last edited by JasonW556; February 23rd 2013 at 10:06 AM.
    Follow Math Help Forum on Facebook and Google+

  4. #4
    Newbie
    Joined
    Feb 2013
    From
    Dover
    Posts
    3

    Re: How much of a given security to stabilize profit/loss

    Update:
    Since I couldn't figure this out mathematically, I wrote a program that would feed in successive values into the P/L equation and looked at the standard deviation of the resulting P/L points. As predicted there was a quantity of SecurityD at which the standard deviation was minimized. Though I did come up with a number, I don't see the problem as solved since this was just a hackish way of coming up with the answer.
    Follow Math Help Forum on Facebook and Google+

  5. #5
    MHF Contributor
    Joined
    Sep 2012
    From
    Australia
    Posts
    3,664
    Thanks
    606

    Re: How much of a given security to stabilize profit/loss

    If it works, then it works.

    Simulation, numerical optimization, and other computational based methods that involve guessing are more common than you think.
    Follow Math Help Forum on Facebook and Google+

Similar Math Help Forum Discussions

  1. profit & loss
    Posted in the Number Theory Forum
    Replies: 1
    Last Post: August 20th 2011, 01:38 PM
  2. Profit Loss Problems
    Posted in the Algebra Forum
    Replies: 4
    Last Post: June 21st 2010, 06:17 AM
  3. Profit & Loss
    Posted in the Algebra Forum
    Replies: 1
    Last Post: November 25th 2009, 09:37 PM
  4. Profit & Loss
    Posted in the Algebra Forum
    Replies: 2
    Last Post: March 27th 2009, 02:55 AM
  5. Profit & Loss
    Posted in the Algebra Forum
    Replies: 1
    Last Post: August 17th 2008, 11:41 PM

Search Tags


/mathhelpforum @mathhelpforum