Ask a questionAsk a question
 

QuestionRecalculate Aggregates

  • Tuesday, November 03, 2009 4:42 AMSkola17 Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Hi All,

    I have a situation where I am suppose to calculate the Standard deviation on a fact table.

    The question is :

    How is it best to calculate this for any subsequent incremental loads?
    Does it mean that I have to recompute the standard deviation evert time after inserting the data in the fact?

    Sridhar
    Sridhar

All Replies

  • Wednesday, November 04, 2009 1:54 PMPhil BrammerMVP, ModeratorUsers MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    First, you need to calculate the standard deviation of *what* exactly?  You can't simply calculate standard deviation across an arbitrary number of records - you need to have and understand what population of the data you will be using to calculate standard deviation.  At the moment, it doesn't sound like you have a firm understanding of the requirements.
    Phil Brammer | http://www.ssistalk.com | Twitter: http://twitter.com/PhilBrammer
  • Wednesday, November 04, 2009 4:18 PMSkola17 Users MedalsUsers MedalsUsers MedalsUsers MedalsUsers Medals
     
    Phil, I have all the understanding of the requisites ..

    All my question states is, what is the best way to calculate Std dev for any incremental loads on table for a relevant set of data !

    Say a table T has 5 columns and I want to calculate std dev grouping 3 columns.
    Table T is then fed the next day.

    Now is there an intelligent way I can avoid running the stddev function on the whole set of T+(delta)T.

    I assumed , the question was comprehendible but nevertheless. hope it makes now !

    Sridhar