Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

[Req] Correlation Data between 2 random US stocks

  • 06-06-2008 1:37pm
    #1
    Closed Accounts Posts: 528 ✭✭✭


    Hi All,

    I'm researching a stock market investment strategy in which risk management will be the top priority. I looking for a facility on the web that tells me the correlation between 2 random and seperate US stocks, ie how they have moved in tandem with each other, against each other or neither over a previous specified period of time.

    Does anyone have experience of such a facility (or similar) on the web? If yes, is the data reliable and can it be obtained cheaply/freely? Are there any other pointers in relation to using it?

    Any help with the above will be greatly appreciated. Thanks In Advance for all responses


Comments

  • Registered Users, Registered Users 2 Posts: 284 ✭✭soddy1979


    You can try registering for the portfolio tracker on Bloomberg.com . Some of the securities exchange websites such as the ISE provide this facility but I'm not too sure about the US stock exchange websites. It would be worth taking a look at them though! The ISE comparison tool and the BB portfolio tracker are free. Best of luck!


  • Registered Users, Registered Users 2 Posts: 8,452 ✭✭✭Time Magazine


    FrCrilly wrote: »
    Hi All,

    I'm researching a stock market investment strategy in which risk management will be the top priority. I looking for a facility on the web that tells me the correlation between 2 random and seperate US stocks, ie how they have moved in tandem with each other, against each other or neither over a previous specified period of time.

    Does anyone have experience of such a facility (or similar) on the web? If yes, is the data reliable and can it be obtained cheaply/freely? Are there any other pointers in relation to using it?

    Any help with the above will be greatly appreciated. Thanks In Advance for all responses
    Get the data and run the correlation yourself. It's very easy in Excel. Use the correl function.

    You have to be very careful though if you're not well-trained in statistics to analyse the data. In general, prices rise and this will provide certain correlation that's not really "true". What you might want to do is look up first differencing the data to remove trends.


  • Posts: 5,589 ✭✭✭ [Deleted User]


    R is a free statistical program that is very powerful (www.r-project.org)

    Google - Econometrics in R by Farnworth (PM me if you can't find it) which explains the basic functions pretty well.

    Make sure you differenced the stocks though [R code: diff(dataname) ] as this will help prevent spurious correlation.


  • Closed Accounts Posts: 863 ✭✭✭Mikel


    Antithetic wrote: »
    You have to be very careful though if you're not well-trained in statistics to analyse the data. In general, prices rise and this will provide certain correlation that's not really "true". What you might want to do is look up first differencing the data to remove trends.
    No you don't want to do that.
    And you shouldn't analyse the prices themselves, you calculate the correlation between the returns. The usual model uses log returns, but you could use arithmetic depending on the situation.
    Yahoo finance might have historical prices, but if you have access to bloomberg that's your best bet.
    Run it over several time periods, see how stable it is.


  • Registered Users, Registered Users 2 Posts: 8,452 ✭✭✭Time Magazine


    Mikel wrote: »
    No you don't want to do that.
    What don't you want to difference? Do you not agree that trends can bias estimates?


  • Advertisement
  • Posts: 5,589 ✭✭✭ [Deleted User]


    Mikel wrote: »
    No you don't want to do that.
    And you shouldn't analyse the prices themselves, you calculate the correlation between the returns. The usual model uses log returns, but you could use arithmetic depending on the situation.
    Yahoo finance might have historical prices, but if you have access to bloomberg that's your best bet.
    Run it over several time periods, see how stable it is.

    What is the usual model?


  • Closed Accounts Posts: 863 ✭✭✭Mikel


    Antithetic wrote: »
    What don't you want to difference? Do you not agree that trends can bias estimates?
    If you trade the stocks you are exposed to any trends, why would you want to eliminate it's effect?
    What is the usual model?
    The usual starting point is to assume that returns are lognormally distributed. They're not but it's a place to start.


  • Registered Users, Registered Users 2 Posts: 3,311 ✭✭✭xebec


    Mikel wrote: »
    If you trade the stocks you are exposed to any trends, why would you want to eliminate it's effect?

    But if you are just looking to analyse the correlation between two stocks and not actually trade in them, where's the problem with removing the correlation caused by the general trend of the market they are traded in and just focusing on the stocks themselves? IMO this would be a more valid statistical test for what the OP is looking for...
    Mikel wrote: »
    The usual starting point is to assume that returns are lognormally distributed. They're not but it's a place to start.

    Also known as the Random Walk Model, it assumes the daily changes in price for a share can be modelled by simulating these as a Normal Dist. Simulating logs instead of the direct share price is an improvement on this as it models greater variations in the share price more easily and often, it is not the basic Random Walk model though.

    OK, back on topic, OP I'd be inclined to go with the differencing suggestions above. Again, beware of getting unexpected results when calculating correlations. And if you are going to be doing any more statistical analysis R is an extremely handy tool, if a little difficult to get used to at first...


  • Closed Accounts Posts: 863 ✭✭✭Mikel


    xebec wrote: »
    But if you are just looking to analyse the correlation between two stocks and not actually trade in them, where's the problem with removing the correlation caused by the general trend of the market they are traded in and just focusing on the stocks themselves? IMO this would be a more valid statistical test for what the OP is looking for...
    Well the OP mentioned risk management in the context of a trading strategy, it makes no sense to me to remove the trend of the market, after all they are in the market.
    What if you are calculating the correlation between two assets in two different asset classes?
    Also known as the Random Walk Model, it assumes the daily changes in price for a share can be modelled by simulating these as a Normal Dist. Simulating logs instead of the direct share price is an improvement on this as it models greater variations in the share price more easily and often, it is not the basic Random Walk model though.
    The reasons for using log normal are that it takes account of relative changes and prices can't become negative


Advertisement