{"_id":"56671dfd32dd550d00f39217","tags":[],"project":"55773a5ba042551900b002cb","initVersion":{"_id":"55773a5ba042551900b002ce","version":"1"},"user":{"_id":"546d17e2eb9cfd1400dd4529","username":"","name":"World Triathlon"},"__v":1,"createdAt":"2015-12-08T18:14:21.466Z","changelog":[{"_id":"5667224166debc1700503f2b","update":"Data Explorer Funnels","type":"added"},{"_id":"5667224166debc1700503f2a","update":"We will be rolling out funnel analysis to the API very shortly.","type":"known"},{"_id":"5667224166debc1700503f29","update":"","type":"added"}],"body":"The [Interactive Data Explorer](https://developers.triathlon.org/v1/page/data-explorer) now contains the ability to perform funnel analysis. This allows a broader range of analysis to be completed with queries that would previously have taken some level of scripting to solve which can now be answered directly.\n\nFor example, consider the question **how many athletes have won both a standard and sprint format WTS event?** \n\nThis problem is easily solved by a funnel with two steps:\n\n1. How many athletes have won a Standard distance WTS race?\n2. Of those athletes how many have won a Sprint distance WTS race?\n\nSimply, these are two queries that occur sequentially using a shared property to identify the athlete to be used in the analysis. It is recommended you use the athlete.id as the ***Actor Property***  in the data explorer. \n\nWe can then construct these two steps using a filter matching the criteria. In our example the first filter is the case where **position** is **equal** to **1** and the **format**  is **equal ** to **Standard**. We then simply duplicate the filter in the second step but replacing Standard for **Sprint**.\n\nThe output of the analysis is shown below which displays the number matching each step of the funnel analysis:\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"{\\n  \\\"result\\\": [\\n    27,\\n    10\\n  ]\\n}\",\n      \"language\": \"json\"\n    }\n  ]\n}\n[/block]\nSo for this analysis 27 athletes have won a WTS Standard distance race and of those **10** have also won a WTS Sprint distance race.\n\nAdding in additional filters for gender informs us that only **3 men**  and **7 women** have completed the WTS format double.\n\nYou are not limited by the number of funnel steps and you have a full range of filters available to construct detailed queries. For example:\n\n* Good in all conditions? How many athletes have won when the temperature is greater than 30 and also less than 20?\n* Good travellers? How many athletes have won on all continents the WTS has visited?\n* Event double? How many athletes have won in specific event combinations e.g. won in Hamburg and London?\n[block:api-header]\n{\n  \"type\": \"basic\",\n  \"title\": \"Special Parameters\"\n}\n[/block]\nThere are a couple of extra options for using funnels for each step:\n\n* **inverted** - A boolean value that excludes events matching this step.\n* **optional** - A boolean value that instructs the funnel to ignore the effects of this step on subsequent steps.\n\nA **with_actors** property which returns a list of those actor properties that are included in each step of the analysis is currently not included in the data explorer but will be available via the API.\n\nNote that the first step of a funnel can be neither inverted nor made optional.","slug":"data-explorer-funnels","title":"Data Explorer Funnels"}

Data Explorer Funnels


The [Interactive Data Explorer](https://developers.triathlon.org/v1/page/data-explorer) now contains the ability to perform funnel analysis. This allows a broader range of analysis to be completed with queries that would previously have taken some level of scripting to solve which can now be answered directly. For example, consider the question **how many athletes have won both a standard and sprint format WTS event?** This problem is easily solved by a funnel with two steps: 1. How many athletes have won a Standard distance WTS race? 2. Of those athletes how many have won a Sprint distance WTS race? Simply, these are two queries that occur sequentially using a shared property to identify the athlete to be used in the analysis. It is recommended you use the athlete.id as the ***Actor Property*** in the data explorer. We can then construct these two steps using a filter matching the criteria. In our example the first filter is the case where **position** is **equal** to **1** and the **format** is **equal ** to **Standard**. We then simply duplicate the filter in the second step but replacing Standard for **Sprint**. The output of the analysis is shown below which displays the number matching each step of the funnel analysis: [block:code] { "codes": [ { "code": "{\n \"result\": [\n 27,\n 10\n ]\n}", "language": "json" } ] } [/block] So for this analysis 27 athletes have won a WTS Standard distance race and of those **10** have also won a WTS Sprint distance race. Adding in additional filters for gender informs us that only **3 men** and **7 women** have completed the WTS format double. You are not limited by the number of funnel steps and you have a full range of filters available to construct detailed queries. For example: * Good in all conditions? How many athletes have won when the temperature is greater than 30 and also less than 20? * Good travellers? How many athletes have won on all continents the WTS has visited? * Event double? How many athletes have won in specific event combinations e.g. won in Hamburg and London? [block:api-header] { "type": "basic", "title": "Special Parameters" } [/block] There are a couple of extra options for using funnels for each step: * **inverted** - A boolean value that excludes events matching this step. * **optional** - A boolean value that instructs the funnel to ignore the effects of this step on subsequent steps. A **with_actors** property which returns a list of those actor properties that are included in each step of the analysis is currently not included in the data explorer but will be available via the API. Note that the first step of a funnel can be neither inverted nor made optional.
added
Data Explorer Funnels
known
We will be rolling out funnel analysis to the API very shortly.