Evidence enables analysts to deliver a polished business intelligence system using SQL and markdown.

Overview

evidence-logo

License: MIT

Business Intelligence for Modern Data Teams

Evidence enables analysts to deliver a polished business intelligence system using SQL and markdown.

It offers a modern development workflow for analysts and a polished user experience for decision-makers.

How It Works

An Evidence project is a collection of markdown documents. Whenever you write SQL queries in those documents, Evidence runs that SQL against your data warehouse.

You can reference the results of those queries directly in your markdown document's text, or you can use them to make charts, graphs, and tables using our built-in component library.

Evidence compiles your markdown documents into a fast and reliable website. It tests your queries and keeps the site up-to-date with your data warehouse.

Evidence supports loops, conditionals, parameterized pages, tests and more. It's easy to get started and you can build data products which are both more sophisticated and dramatically easier to use than what you can build with a typical BI tool. how-it-works

Getting Started

Evidence is in alpha. A lot of things will change between now and our stable release.

Installation

Check out the documentation for a complete walk through.

npx degit evidence-dev/template my-project
cd my-project 
npm install 
npm run dev 

Join the Evidence Community

Join our Slack channel to get involved in the community's discussion, share what you're working on, or request features.

Follow us on Twitter to receive the latest updates on Evidence.

Contributing

If you are interested in contributing, please join us on our slack channel, open an issue, or contribute a pull request.

License

Evidence is licensed under the MIT license. See the LICENSE file for licensing information.

Comments
  • Persistent query show/hide states

    Persistent query show/hide states

    As a user in dev mode, it's frustrating that query results collapse every time the page reloads.

    Desired behaviour:

    • The query results are kept as shown / hidden based on what the state was before reload

    Rough approach

    • Store the state of each query in local storage, and read from there on reload

    Questions

    • This seems like a weird implementation of storage - I feel like you typically put svelte store variables in store.js?
    • But since (I think) you want to control each query independently, you'd perhaps need to independently make variables for each query - and you don't know how many there are before the queries are compiled. So I put them in the component instead.

    Next

    • It would seem logical to also include the show/hide state of the query text itself, once we've worked out the best approach for this
    opened by archiewood 19
  • Decide on Chart Architecture

    Decide on Chart Architecture

    📢 Feedback Needed - help us build an amazing chart library!

    We've heard from several community members that they want to see more capabilities built into our chart library. We've also received requests to include support for third-party chart libraries in Evidence (like Vega, Highcharts, Plotly and Chart.js).

    Given the importance of charts to the overall experience of using Evidence, we want to do a thorough assessment of our options for building the best chart library you've ever used.

    We will post our criteria and thoughts in this issue, and hope to hear feedback about:

    • What you would like to see in our chart library (please let us know if your ideas are must-haves or nice-to-haves for you)
    • Any experience you've had with third-party chart libraries (positive or negative!)
    enhancement components 
    opened by hughess 19
  • issue-312 custom formats

    issue-312 custom formats

    You can enable this feature by simply adding a file named sites/example-project/.custom-settings.json with content:

    {
      "panelEnabled": true
    }
    

    Example of how this works right now on the UI (you should be able to apply it by aliasing the format name in query): See https://github.com/evidence-dev/evidence/pull/325#issuecomment-1160726392

    Also, I scoped creeped basic code formatting with prettier. Currently only meant to be run manually using pnpx prettier --write <file-to-be-formatted>. Errors may show up if you have the vscode prettier plugin installed, however this won't cause any build issues or preventing your from making merges.

    opened by ud3sh 16
  • 100 percent stacked bar and area charts

    100 percent stacked bar and area charts

    This PR implements 100% stacked bar and area charts using the type prop (type=stacked100).

    How It Works

    • When you use type=stacked100, a new function called getStackPercentages will calculate the percentage of the group total for each row in the table
    • New columns are appended to the data object: (1) total for each X - sum up y grouped by x, (2) percentage - for each row, the y value as a % of the “total for each X”
    • The chart treats the percentage column as the y-axis for the chart

    Other Changes

    • This PR adds props to add more control to charts:
      • yMax: set the maximum value of the y-axis. Helpful if you are passing your own 100% stacked data to a normal bar chart
      • yAxisLabels and xAxisLabels: allow you to turn on or off labels on the x and y axis

    Current Limitations

    • This only works in BarChart and AreaChart and does not work in composable charts
    • If you use a y-axis title, it gets cut off by bars when using 100% stack
    • If your y column has a format tag included in it (e.g., sales_usd), the column name resulting from the aggregation will append another format tag to the end for percentage (e.g., sales_usd_pct ---> Sales Usd (%))
    opened by hughess 14
  • Update chart size on render finished

    Update chart size on render finished

    I was playing around and found an issue related to chart layout when performing client side navigation

    https://user-images.githubusercontent.com/14029371/199779439-3b1c19a1-0d19-408e-980d-275415adebd1.mov

    I'm new using echarts so not sure if this would be the most idiomatic solution to this problem. Happy to hear your thoughts

    opened by afzalsayed96 11
  • Athena support

    Athena support

    Addresses #472

    Here's a first pass. It will need some documentation and cleanup, and also I haven't been able to get the test to run locally for some reason.

    opened by rabidaudio 10
  • Explicit unicode column names are converted to lowercase when using postgresql

    Explicit unicode column names are converted to lowercase when using postgresql

    Bug Description

    Serbian cyrilic: Опис is converted to опис.

    select description as "Опис"
    from forms f
    

    image

    Serbian latin:

    select description as "Šuma"
    from forms f
    

    image

    Severity

    • [x] Low - I'm able to keep using Evidence as normal, but flagging this for the team to fix

    Expected Behavior

    Workarounds There doesn't seem to be workaround

    Environment Information Operating System: Windows 10 Node version (node -v): 19.1.0 npm version (npm -v): 8.9.13 Package versions (npm list --depth=0): `@evidence-dev/[email protected]

    Database:

    • [x] Postgres
    bug 
    opened by majkinetor 9
  • [Feature]: Adds support for scrolling on datatable

    [Feature]: Adds support for scrolling on datatable

    This is a quick experiment to show how UX on QueryDataTable can be improved by listening to vertical wheel event on table and updating the rows rendered accordingly.

    https://user-images.githubusercontent.com/14029371/202231411-9e3c85ba-924c-438c-9a69-21370a21bdbe.mov

    opened by afzalsayed96 9
  • BigValue Component

    BigValue Component

    Adds a beloved BI feature: the Big Number Viz™ to Evidence.

    Includes:

    • Number
    • Sparkline
    • Comparison
    • Comparison is configurable for "down is good"
    • Multiple Big Numbers stack into a row
    • Smart enough defaults that only the data prop is required

    BigValue Example

    opened by mcrascal 9
  • add separate download data option to charts

    add separate download data option to charts

    Description

    Resolves #528

    Hopefully, this is what was requested.

    • DownloadData now has text as prop ("Download Data", "Save Image", etc). Might be good to rename (DownloadButton)
    • Data added as prop to ECharts component
    • Echarts now has download option for Chart PNG and CSV data

    Before:

    Screen Shot 2022-12-14 at 7 47 36 PM

    After:

    https://user-images.githubusercontent.com/14843458/207746387-3914617d-e623-474d-91bd-a65443d3fd4f.mp4

    opened by yukseltron 8
  • Postgres Connector Case Normalization Fix

    Postgres Connector Case Normalization Fix

    Context:

    • User reported difficult connecting to Cube.js via their Postgres SQL API
    • Cube.js compiles queries, and then passes the results back to the query engine.
    • Cube.js by default uses camel case for the names of the fields that are passed back

    Problem

    • The postgres connector lowercases all of the field names: myColumn -> mycolumn
    • But the evidenceType column name is not lowercased
    • This means that if when Evidence looks for the type of mycolumn it cannot find it.

    Result: image

    Proposed fix

    • Lowercase the field name for the column types object also
    opened by archiewood 8
  • The PDF generated will only contain the columns visible in the UI when the table contains multiple columns. Only the first few columns are displayed when a scroll bar is present in the resulted table.

    The PDF generated will only contain the columns visible in the UI when the table contains multiple columns. Only the first few columns are displayed when a scroll bar is present in the resulted table.

    The PDF generated will only contain the columns visible in the UI when the table contains multiple columns. Only the first few columns are displayed when a scroll bar is present in the resulted table. Displayissue1

    opened by arunqa 4
  • Patch fix for 100% stacked charts

    Patch fix for 100% stacked charts

    Description

    This PR adds a patch fix to 100% stacked charts to avoid them erroring out on changes to the data object or page.

    Here is the rough approach to building 100% stacked charts:

    • In Chart.svelte, we receive the y column(s) as inputted by the user (e.g., sales)
    • The total of the y column is calculated
    • Each y column value is divided by the y column total to get the percentage for use in the stack
    • Once the stacked percentages are calculated, the y variable name is overwritten as y + "_pct" (e.g., sales_pct)

    The problem appears when the chart re-runs reactively (either from a change to the data object or to the page):

    • Chart.svelte's script tag re-runs, but the y variable has not been reset to the original name supplied by the user (e.g., it still shows up as sales_pct)
    • Chart.svelte runs a check of the inputted columns and throws an error when it can't find sales_pct in the dataset

    Naive Fix

    The naive fix to this is to remove "_pct" from the y variable so Chart.svelte can find it in the dataset. We only want to do this if it's a 100% stacked chart and if it's not the first run of the chart.

    This PR adds a new variable originalRun which is true when the chart loads, and is set to false when the y variable is overwritten. A check has been added in Chart.svelte which will reset the y variable when it finds originalRun===false.

    This is a bandaid fix to get 100% stacked charts working. The fix doesn't negatively impact our other charts, but it doesn't solve the root cause of the issue, which is that the y variable is not reset to the original value supplied by the user when 100% stacked charts re-run reactively.

    Checklist

    opened by hughess 2
  • Exported dates should be in ISO format

    Exported dates should be in ISO format

    Bug Description When downloading data in Evidence, date columns are exported in full javascript date object format. This makes them difficult to use in other tools.

    We should export dates in ISO format (YYYY-MM-DD) so the dates are usable.

    Severity

    • [x] Low - I'm able to keep using Evidence as normal, but flagging this for the team to fix

    Error Messages and Screenshots CleanShot 2022-12-23 at 14 46 57@2x

    Details

    • This is caused by the date parsing logic used across the product - we need to convert dates into javascript date objects to standardize the treatment of timezones across databases and browsers
    • In the date parsing logic, we may be able to convert the dates back into strings - either within the parsing logic itself, or within the component where data will be exported
    bug 
    opened by hughess 0
  • Improved DataTable

    Improved DataTable

    Description

    This PR is the first step in implementing improved tables in Evidence (see #468). It covers the following improvements to our DataTable component:

    • Horizontal scroll: if you have more columns than the page width can display, the table with automatically allow for horizontal scroll (rather than truncate the column contents as it currently does)

    • Column selection: select specific columns to include in your table by using the new Column component like so:

      <DataTable data={my_query}>
         <Column id=date/>
         <Column id=country/>
         <Column id=sales/>
      </DataTable>
      
      • If you don't select any columns, the table will include all columns in the query result:
      <DataTable data={my_query}/>
      
    • Column-specific settings: using props within the Column component, you can make decisions on a column-by-column basis for the following options (more to follow in the future):

      • title: override the title of the column
      • align: left / center / right align the contents and header of the column
    • New pagination approach: the data scrubber in DataTable has been replaced by page numbers and buttons shown at the bottom of the table

    • Sortable Columns: you can sort columns by clicking on the column header (using sortable=true; it is on by default)

    • Search: using search=true, you can add a search bar to the top of your table. This is off by default to avoid cluttering your page

    • Updated data download: when you click the download button at the bottom right of your table, it will export only the columns you've supplied to the table through the Column components - we're hoping this will be helpful in cases where you have many columns in your query and only want to export what's visible to your readers

    • Updated table styling options:

      • rowNumbers: true | false - turns on or off row index numbers (off by default)
      • rowLines: true | false - turns on or off borders at the bottom of each row (on by default)
      • rowShading: true | false - shades every second row in light grey (off by default)

    Examples

    Sample Table

    datatable-all

    Interactive Demonstration

    datatable-interactive

    Development Demonstration

    datatable-development

    Checklist

    • [x] For UI or styling changes, I have added a screenshot or gif showing before & after
    • [x] I have added a changeset

    Issues with this PR

    • Table generation code: there is likely a way to implement the table generation logic more concisely.
      • The problem with this implementation is it requires a lot of duplication to cover these two scenarios:
        1. Columns are passed explicitly through Column components
        2. No columns are passed (fallback to full data object)
      • I tried preparing all data in the script tag before generating the table (removing the duplicated logic in the main Svelte code), but this caused the table to flash in an unfinished state when each page was loaded
    • Error handling: errors currently do not get handled in an ErrorChart as in the previous DataTable. This is because the error needs to be passed from the Column component to the DataTable, and this will take a bit more effort to get working
    • Sort icon styling:
      • Ideally, the column sort icons would be vertically centered
      • We may need an icon to indicate that the columns are sortable (e.g., show both up and down errors when not in a sorted state). I left these out to keep the table headers looking clean, but it might be required for usability
      • Columns shift quite a bit when the sort button is clicked, since column widths are determined by the content visible on the page
    • Pagination styling: alignment of elements needs a bit of work here. This is not an issue now, but will be in the future when we want to offer more font size/density options within tables
    • Data exporting
      • Date format: dates are exported in a format that is not usable in other tools. It is currently using javascript Date object formatting, but an ISO string would be better. This can either be fixed in the table or (preferably) in the date parsing logic implemented throughout Evidence
      • Overridden column names: overridden column names are not included in data export (only raw sql column names)
    • Search behaviour:
      • Works across all columns: search works across all columns of the underlying dataset. This may produce unexpected behaviour, as you can search within columns that are not visible in the table
      • Jumping content: When you navigate to a page of data with fewer records, content from lower down on the page jumps up to fill the gap left by the missing records
    • Mobile search experience: the automatic zoom-in when typing in the search bar on mobile makes the experience worse. Fix for this is increasing the font size until zoom is not required, but the required font size makes the search bar stand out from the contents of the page too much
    • Print formatting: print formatting can be a lot better (e.g., pagination buttons remain in print version)
      • A stopgap solution here could be to display a nicer looking “X of Y records” message rather than the pagination buttons
    • Search icon styling: the search icon in development mode appears in a light grey (as expected), but it appears black in production (see vercel dev-workspace preview for an example)
    opened by hughess 2
  • Null series in chart does not appear in legend

    Null series in chart does not appear in legend

    Bug Description In a multi-series chart, a null series will not appear in the legend. On a tooltip, the series will be given a sequenced name like "series1"

    Severity

    • [x] Low - I'm able to keep using Evidence as normal, but flagging this for the team to fix

    Expected Behavior Would expect to see a series called null in the legend, and for that series to appear as null in the tooltip.

    Error Messages and Screenshots CleanShot 2022-12-21 at 08 03 45@2x

    bug 
    opened by hughess 0
Releases(@evidence-dev/[email protected])
This repo contains a simple but effective tool made using python which can be used for quality control in statistical approach.

📈 Statistical Quality Control 📉 This repo contains a simple but effective tool made using python which can be used for quality control in statistica

SasiVatsal 8 Oct 18, 2022
Statistical Analysis 📈 focused on statistical analysis and exploration used on various data sets for personal and professional projects.

Statistical Analysis 📈 This repository focuses on statistical analysis and the exploration used on various data sets for personal and professional pr

Andy Pham 1 Sep 03, 2022
An orchestration platform for the development, production, and observation of data assets.

Dagster An orchestration platform for the development, production, and observation of data assets. Dagster lets you define jobs in terms of the data f

Dagster 6.2k Jan 08, 2023
bigdata_analyse 大数据分析项目

bigdata_analyse 大数据分析项目 wish 采用不同的技术栈,通过对不同行业的数据集进行分析,期望达到以下目标: 了解不同领域的业务分析指标 深化数据处理、数据分析、数据可视化能力 增加大数据批处理、流处理的实践经验 增加数据挖掘的实践经验

Way 2.4k Dec 30, 2022
Tools for working with MARC data in Catalogue Bridge.

catbridge_tools Tools for working with MARC data in Catalogue Bridge. Borrows heavily from PyMarc

1 Nov 11, 2021
A set of tools to analyse the output from TraDIS analyses

QuaTradis (Quadram TraDis) A set of tools to analyse the output from TraDIS analyses Contents Introduction Installation Required dependencies Bioconda

Quadram Institute Bioscience 2 Feb 16, 2022
Python package for processing UC module spectral data.

UC Module Python Package How To Install clone repo. cd UC-module pip install . How to Use uc.module.UC(measurment=str, dark=str, reference=str, heade

Nicolai Haaber Junge 1 Oct 20, 2021
An extension to pandas dataframes describe function.

pandas_summary An extension to pandas dataframes describe function. The module contains DataFrameSummary object that extend describe() with: propertie

Mourad 450 Dec 30, 2022
Single-Cell Analysis in Python. Scales to >1M cells.

Scanpy – Single-Cell Analysis in Python Scanpy is a scalable toolkit for analyzing single-cell gene expression data built jointly with anndata. It inc

Theis Lab 1.4k Jan 05, 2023
Driver Analysis with Factors and Forests: An Automated Data Science Tool using Python

Driver Analysis with Factors and Forests: An Automated Data Science Tool using Python 📊

Thomas 2 May 26, 2022
MEAD: A Large-scale Audio-visual Dataset for Emotional Talking-face Generation [ECCV2020]

MEAD: A Large-scale Audio-visual Dataset for Emotional Talking-face Generation [ECCV2020] by Kaisiyuan Wang, Qianyi Wu, Linsen Song, Zhuoqian Yang, Wa

112 Dec 28, 2022
BigDL - Evaluate the performance of BigDL (Distributed Deep Learning on Apache Spark) in big data analysis problems

Evaluate the performance of BigDL (Distributed Deep Learning on Apache Spark) in big data analysis problems.

Vo Cong Thanh 1 Jan 06, 2022
Port of dplyr and other related R packages in python, using pipda.

Unlike other similar packages in python that just mimic the piping syntax, datar follows the API designs from the original packages as much as possible, and is tested thoroughly with the cases from t

179 Dec 21, 2022
Making the DAEN information accessible.

The purpose of this repository is to make the information on Australian COVID-19 adverse events accessible. The Therapeutics Goods Administration (TGA) keeps a database of adverse reactions to medica

10 May 10, 2022
Python-based Space Physics Environment Data Analysis Software

pySPEDAS pySPEDAS is an implementation of the SPEDAS framework for Python. The Space Physics Environment Data Analysis Software (SPEDAS) framework is

SPEDAS 98 Dec 22, 2022
Codes for the collection and predictive processing of bitcoin from the API of coinmarketcap

Codes for the collection and predictive processing of bitcoin from the API of coinmarketcap

Teo Calvo 5 Apr 26, 2022
A neural-based binary analysis tool

A neural-based binary analysis tool Introduction This directory contains the demo of a neural-based binary analysis tool. We test the framework using

Facebook Research 208 Dec 22, 2022
PrimaryBid - Transform application Lifecycle Data and Design and ETL pipeline architecture for ingesting data from multiple sources to redshift

Transform application Lifecycle Data and Design and ETL pipeline architecture for ingesting data from multiple sources to redshift This project is composed of two parts: Part1 and Part2

Emmanuel Boateng Sifah 1 Jan 19, 2022
Code for the DH project "Dhimmis & Muslims – Analysing Multireligious Spaces in the Medieval Muslim World"

Damast This repository contains code developed for the digital humanities project "Dhimmis & Muslims – Analysing Multireligious Spaces in the Medieval

University of Stuttgart Visualization Research Center 2 Jul 01, 2022
CINECA molecular dynamics tutorial set

High Performance Molecular Dynamics Logging into CINECA's computer systems To logon to the M100 system use the following command from an SSH client ss

J. W. Dell 0 Mar 13, 2022