Skip to content
This repository has been archived by the owner on Aug 16, 2021. It is now read-only.

kimmobrunfeldt/lysis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lysis

Lysis offers simple way to create visual analysis from CSV file using Google charts. This tool was created to more easily visualize Google Form's responses. Google offers a summary of responses, but it doesn't cover every aspect of answers.

Lysis turns this

class Analysis(analysis.Analysis):
    """Pizza survey

    Opinions of pizza
    """

    @draw
    def pizza_likers_haters_pie(self, rows):
        """Pizza likers/haters ratio pie chart

        Who likes pizza and who doesn't
        """
        counter = Counter(row[1] for row in rows)
        headers = [['Answer', 'Count']]

        return {
            'chart': 'PieChart',
            'data': headers + [(x, y) for x, y in counter.items()]
        }

To this:

Pizza survey

It produces HTML file which will show all charts created by analysis methods. You can use any chart type that Google supports. If want something else than charts, just customize render function.

Template which produces the output is very minimal, it can easily be edited to suit your needs.

Install

First install Python and [pip](http://en.wikipedia.org/wiki/Pip_(package_manager\)).

Then run:

pip install -r requirements.txt

Usage

  1. Create your data analyzing methods to youranalysis.py file.

  2. Run python main.py data.csv

  3. Open output/index.html to see the analytics

Check examples in examples directory. Get started with simple-pizza example!

Charts are customizable by adding key options to dict which is returned by analysis method. For example all available options for pie chart is listed in Google's documentation.

Labels in HTML are extracted from docstrings in Analysis class' and its methods.

About

Dead simple way to create visual charts from CSV

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published