7 Replies Latest reply: Jun 7, 2018 2:59 AM by Mariam Ovasheli RSS

    Share of Total

    Mariam Ovasheli

      Hello,

      I have Same Question I had day before and I cant come up to its solution  so ask your help Again.

      I need to calculate market Share of stations Within the district Where this stations is.  there is also other stations in this district so I need

      to know what share does ''Neogas''s  stations have.

      (Sum({<Owner={'NeoGas'}, YearMonthMY = {'>=$(vStartDate)<=$(vEndDate)'} >}Volume)

      /


      sum( {<District, YearMonthMY = {'>=$(vStartDate)<=$(vEndDate)'} >}  total Volume))

       

      this is the formula that I use but it is not working and can you please help me or at least tell me what does this formula do?


        • Re: Share of Total
          Sunny Talwar

          Where are you using this expression? In a chart or text box object?

            • Re: Share of Total
              Mariam Ovasheli

              In scatter plot chart. I Think I Did it

              (sum({<Owner = {'Neogas'},YearMonthMY = {'>=$(vStartDate)<=$(vEndDate)'} >}Volume)

              /

              sum(aggr( sum({<YearMonthMY = {'>=$(vStartDate)<=$(vEndDate)'}>}Total <District> Volume),District, StationName)))

               

              -

              (sum({<Owner = {'Neogas'},YearMonthMY = {'>=$(v2StartDate)<=$(v2EndDate)'} >}Volume)

              /

              sum(aggr( sum({<YearMonthMY = {'>=$(v2StartDate)<=$(v2EndDate)'}>}Total <District> Volume),District, StationName))

              )


              It Looks like correct.


              As long as you are here I ask you one more Question Please, How it is possible to make parallel dimension of date so I Use date Field and not that many variables?

            • Re: Share of Total
              David Forest

              Are you talking about a Master calendar?

              Creating A Master Calendar

                • Re: Share of Total
                  Mariam Ovasheli

                  To load date as two different fields and Use in Expression to compare different Periods. I need to compare  dates I select To each other  and for that I need Two date Field but both must be connected to my data  like parallel dimension or some thing like this.

                • Re: Share of Total
                  David Forest

                  Please provide an example of specific comparison with data and outcomes.

                  Set Analysis may provide a way to accomplish it.

                    • Re: Share of Total
                      Mariam Ovasheli

                      This is Expression that I use. I have 4 variables and user should have write that variables to compare this periods.

                      and I wonder If there is a chance I can do this with two date fields to they don;t have to write dates but select from filter.

                      period.JPG

                      Sum(Aggr(If(Rank(Sum(Volume)) <= 10,


                      (Sum({<Owner,YearMonthMY = {'>=$(vStartDate)<=$(vEndDate)'}>}Volume)



                      /

                      Sum({<YearMonthMY = {'>=$(vStartDate)<=$(vEndDate)'}>}Total Volume)


                      )

                      -

                      (Sum({<Owner,YearMonthMY = {'>=$(v2StartDate)<=$(v2EndDate)'}>}Volume)



                      /

                      Sum({<YearMonthMY = {'>=$(v2StartDate)<=$(v2EndDate)'}>}Total Volume)

                      )


                      )


                      , Owner))