Skip to content

Commit

Permalink
update bulk example
Browse files Browse the repository at this point in the history
  • Loading branch information
ylasri committed Aug 23, 2020
1 parent 81b1660 commit b7c0d4c
Show file tree
Hide file tree
Showing 5 changed files with 81 additions and 75 deletions.
155 changes: 80 additions & 75 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,85 @@
# Kibana Plugin - Cohort Analysis

This project is a simple tutorial for Kibana new comers trying to develop their own vizualisation plugin. The actual usecase of this plugin is to create a custom cohort visualization based on React and Elastic EUI.

As plugin architecture is being under heavy redesign in 7.x and documentation is rather obscure, I did my best to create something simple that works. The code is also basic, I am JS & React beginner.

This repository is for Kibana v7.8.x plugin New Platform (NP)

This plugin is inspired from the [elo7 plugin](https://github.com/elo7/cohort)

## Sample Screenshots

Few screen shots which makes it very easy to understand.

<img src="./screens/cohort_table.png" align="middle">
This is an example of Cohort analysis using Elastic EUI Table



<img src="./screens/cohort_chart.png" align="middle">
This is an example of Cohort analysis using Elastic EUI Charts

<img src="./screens/cohort_dashboard.png" align="middle">
This is an example of Cohort analysis Visualization inside a dashboard.

<img src="./screens/canevas.png" align="middle">
This is an example of Cohort analysis Visualization inside a Canevas Workpad.




## Usage

The **total** metric is the value that determine y-axis. Can be either a count or a sum. It also possible to use the percentual as y value just marking the option `Show percetual values`.

<img src="./screens/metric.png" align="middle">


The **cohort date** bucket is the date used to draw the chart lines. Each bucket is a line in this chart. It should be a date histogram.

<img src="./screens/date.png" align="middle">

The **cohort period** bucket is the "cohort" itself that determine the x-axis. It should be a numeric histogram.

<img src="./screens/period.png" align="middle">

## Installing the plugin

The plugin can then be installed like this

```
kibana-plugin install https://github.com/synapticielfactory/kibana_cohort/releases/download/v7.8.0/kibana_cohort_7.8.0_0.0.1.zip
```

## Install on Windows

````
kibana-plugin.bat install https://github.com/synapticielfactory/kibana_cohort/releases/download/v7.8.0/kibana_cohort_7.8.0_0.0.1.zip
Attempting to transfer from https://github.com/synapticielfactory/kibana_cohort/releases/download/v7.8.0/kibana_cohort_7.8.0_0.0.1.zip
Transferring 815445 bytes....................
Transfer complete
Retrieving metadata from plugin archive
Extracting plugin archive
Extraction complete
Plugin installation complete
````

## Remove on Windows

````
kibana-plugin.bat list
[email protected]
kibana-plugin.bat remove kibana_cohort
Removing kibana_cohort...
Plugin removal complete
````

# Cohort Analysis

This part was found [here](https://www.kdnuggets.com/2016/05/clevertap-use-cohort-analysis-improve-customer-retention.html)
This interesting article was found [here](https://www.kdnuggets.com/2016/05/clevertap-use-cohort-analysis-improve-customer-retention.html)

Long-term success for app developers does not mean only getting someone to download their app, but also getting them to make repeat visits. To get to the must-have value proposition of your app product, you need to go beyond vanity metrics – like download counts and even daily active users (DAU) / monthly active users (MAU) – that only measure growth and retention superficially. You need to dig deeper into your app using a method –Cohort Analysis.

Expand Down Expand Up @@ -89,77 +168,3 @@ From this data, you can develop a systematic, quantitative approach to know how
Conclusion

The power of cohort analysis lies in the fact that, it enables not only to view which customers leave and when they leave, but also to understand why the customers leave your app – so that you can fix it. That’s how one can identify how well the users are being retained and also determine the primary factors driving the growth, engagement and revenue for the app.

# Kibana Plugin - Cohort Analysis

This project is a simple tutorial for Kibana new comers trying to develop their own vizualisation plugin. The actual usecase of this plugin is to create a custom cohort visualization based on React and Elastic EUI.

As plugin architecture is being under heavy redesign in 7.x and documentation is rather obscure, I did my best to create something simple that works. The code is also basic, I am JS & React beginner.

This repository is for Kibana v7.8.x plugin New Platform (NP)

This plugin is adapted from the [elo7 plugin](https://github.com/elo7/cohort)

## Sample Screenshots

Few screen shots which makes it very easy to understand.

<img src="./screens/cohort_table.png" align="middle">
This is an example of Cohort analysis using Elastic EUI Table



<img src="./screens/cohort_chart.png" align="middle">
This is an example of Cohort analysis using Elastic EUI Charts

<img src="./screens/cohort_dashboard.png" align="middle">
This is an example of Cohort analysis Visualization inside a dashboard.


## Usage

The **total** metric is the value that determine y-axis. Can be either a count or a sum. It also possible to use the percentual as y value just marking the option `Show percetual values`.

<img src="./screens/metric.png" align="middle">


The **cohort date** bucket is the date used to draw the chart lines. Each bucket is a line in this chart. It should be a date histogram.

<img src="./screens/date.png" align="middle">

The **cohort period** bucket is the "cohort" itself that determine the x-axis. It should be a numeric histogram.

<img src="./screens/period.png" align="middle">

## Installing the plugin

The plugin can then be installed like this

```
kibana-plugin install https://github.com/synapticielfactory/kibana_cohort/releases/download/v7.8.0/kibana_cohort_7.8.0_0.0.1.zip
```

## Install on Windows

````
kibana-plugin.bat install https://github.com/synapticielfactory/kibana_cohort/releases/download/v7.8.0/kibana_cohort_7.8.0_0.0.1.zip
Attempting to transfer from https://github.com/synapticielfactory/kibana_cohort/releases/download/v7.8.0/kibana_cohort_7.8.0_0.0.1.zip
Transferring 815445 bytes....................
Transfer complete
Retrieving metadata from plugin archive
Extracting plugin archive
Extraction complete
Plugin installation complete
````

## Remove on Windows

````
kibana-plugin.bat list
[email protected]
kibana-plugin.bat remove kibana_cohort
Removing kibana_cohort...
Plugin removal complete
````
Binary file added dataset/chart.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions dataset/food_relay_es_bulk.csv.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
POST _bulk
{"index": {"_index": "food_relay", "_id": 262}}
{"order_id": "262", "order_date": "2009-01-11", "user_id": "47", "total_charges": "50.67", "common_id": "TRQKD", "pup_id": "2", "pickup_date": "2009-01-12", "first_order_date": "2009-01-11", "dayUntilReturn": "0"}
{"index": {"_index": "food_relay", "_id": 278}}
Expand Down
Binary file added dataset/table.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added screens/canevas.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit b7c0d4c

Please sign in to comment.