Forum Discussion

Arnault_'s avatar
Arnault_
Resolver III
5 years ago
Solved

MdxScript(Model) / Calulcation error in (...)

Hi All, I have created several mesures to define a confidence interval for my data. The measures seem to work fine when I use the "card" visual. When I try to use a "table" visual, I get that error...
  • Arnault_'s avatar
    Arnault_
    5 years ago

    Finally, I have tried the following and it works (it seems).

    Selling price - conf. level 95% = 
    VAR Alpha = ( 1 - 0.95 )
    VAR Size =
        CALCULATE (
            COUNTROWS ( DISTINCT ( 'FACT Order'[packing_line_id] ) ),
            FILTER ( 'FACT Order', 'FACT Order'[selling price] <> 0 )
        )
    VAR SDev = [Selling price (Std Dev)]
    VAR Result =
        CONFIDENCE.NORM ( Alpha, SDev, Size )
    RETURN
        IF ( SDev > 0,  Result, BLANK () )
  • v-xulin-mstf's avatar
    v-xulin-mstf
    5 years ago

    Hi Arnault_,

     

    Congratulations, my idea is also like: IF ( SDev > 0, Result, BLANK () )

     

    Best Regards,

    Link