Upgrade to Pro — share decks privately, control downloads, hide ads and more …

KPIs

 KPIs

Key Performance Indicators: Quantifying User Delight

Akshay Shah

May 08, 2013
Tweet

More Decks by Akshay Shah

Other Decks in Programming

Transcript

  1. Product Analytics

    View Slide

  2. Verify
    that each
    product iteration
    delights users
    more.

    View Slide

  3. Key Pick few enough to remember.
    Quality beats quantity.
    Focus on perceived utility, not
    execution speed or error rate.
    Choose simple metrics. KPIs are
    summaries, not the whole story.
    Performance
    Indicators
    Define
    Success

    View Slide

  4. Who Cares?
    Snapshot of company health and
    progress.
    Help customers follow best
    practices. Identify failing accounts.
    Prioritize projects and benchmark
    success. Drive design.
    Board
    CS
    Product

    View Slide

  5. Desiderata
    Support per-org queries with on-
    the-fly aggregation.
    Aggregate over days, weeks,
    months, quarters, and years.
    HTML tables in debug plus flat file
    downloads.
    Sharding
    Periods
    UI

    View Slide

  6. Ugh.

    View Slide

  7. It's Easy!

    View Slide

  8. # In fanmgmt. kpi s. constants. your_pi llar_name
    from . base i mport Kpi Enum, Kpi EnumValue
    class ExampleKpi (Kpi Enum) :
    WIDGETS = Kpi EnumValue(1, ' wi dgets' , _(' Wi dgets Produced' ) )
    PERCENT_GNOME = Kpi EnumValue(
    2,
    ' percent_gnome' ,
    _(' % Made by Gnomes' ) ,
    explanati on=' Gnomes are small humanoi ds' )
    First Define your KPIs.

    View Slide

  9. Second Add your pillar.
    # In fanmgmt. kpi s. constants. pi llar
    from . your_pi llar_name i mport ExampleKpi
    class Pi llar(OrderedRi chEnum) :
    . . .
    EXAMPLE = _Pi llar(4, ' example' , _(' Example' ) , ExampleKpi )

    View Slide

  10. # In your app' s tasks module
    # Schedule through debug, send to KPI queue
    from fanmgmt i mport kpi
    @kpi . task(kpi . Pi llar. EXAMPLE)
    def count_wi dgets(organi zati on, start, end, track) :
    # Type si gnature i s i mportant!
    wi dgets = Wi dget. obj ects. fi lter(**params) . count()
    gnome = Wi dget. obj ects. fi lter(**other_params) . count()
    track. count(ExampleKpi . WIDGETS, wi dgets) )
    track. fracti on(ExampleKpi . PERCENT_GNOME, gnome, wi dgets)
    Last Write some tasks.

    View Slide

  11. Forgot about state.

    View Slide

  12. var toggleWi dget = functi on() {
    // HearsayEvents i s already i n the global scope.
    var kpi = new HearsayEvents. Tracker("myPi llar") ;
    // Start si mple.
    kpi . track("myEvent") ;
    // More complex. . . i f you must.
    kpi . track("complexEvent", "subtype1", 100) ;
    };
    First Track your events.

    View Slide

  13. var toggleWi dget = functi on() {
    // HearsayEvents i s already i n the global scope.
    var kpi = new HearsayEvents. Tracker("myPi llar") ;
    // Start si mple.
    kpi . track("myEvent") ;
    // More complex. . . i f you must.
    kpi . track("complexEvent", "subtype1", 100) ;
    };
    First Track your events.

    View Slide

  14. Optional Subclass the tracker.
    var myTracker = functi on() {
    // Easy to take an obj ect and do some di spatch logi c
    thi s. trackComplex = functi on(j sObj ect) {
    thi s. track("cli cked_" + j sObj ect. name) ;
    thi s. track("num_" + j sObj ect. name, "", j sObj ect. length) ;
    };
    };
    myTracker. prototype = new HearsayEvents. Tracker("myPi llar") ;

    View Slide

  15. PRs Welcome Tooltips. Date pickers. Charts. AJAX.

    View Slide

  16. Track KPIs, <3 Users

    View Slide

  17. All Good?
    fanmgmt/kpi/README.markdown

    View Slide