Giter Site home page Giter Site logo

vega.github.io's Introduction

vega.github.io

The vega landing page

vega.github.io's People

Contributors

ajturner avatar amitkaps avatar apollonian avatar arvind avatar binste avatar domoritz avatar imgbot[bot] avatar jainpawan21 avatar jheer avatar kanitw avatar kristw avatar marcprux avatar na399 avatar okal avatar randyzwitch avatar willium avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

vega.github.io's Issues

Convert the page into React.js

Hi, I will convert the page in React.js and will use Chakra UI. Thanks.

Demonstration of the page I will be working on:

image
image
image

Vega Lite Error Response: Cannot convert undefined or null to object

I am new to vega. I am trying to create a Gantt chart visualisation using vega code but for some reason the code returns the error:
Cannot convert undefined or null to object
Here's the vega code I wrote:

{
  "$schema": "https://vega.github.io/schema/vega/v5.json",
  "description": "A Gantt chart representing the availability of different datasets over time.",
  "padding": 5,
  "autosize": "fit",
  "data": [
    {
      "name": "table",
      "url": {
        // Specify the Elasticsearch index to query
        "index": "availability-index",
        "body": {
          "size": 10000,
          "_source": ["start_timestamp", "end_timestamp", "dataset_name", "is_available"],
          // Define any query here. For a full time range, you can use a match_all query
          "query": {
            "match_all": {}
          }
        }
      },
      // Use Elasticsearch's _source field to extract the values
      "format": { "property": "hits.hits._source" },
      "transform": [
        {
          "type": "formula",
          "as": "start_date",
          "expr": "toDate(datum.start_timestamp)"
        },
        {
          "type": "formula",
          "as": "end_date",
          "expr": "toDate(datum.end_timestamp)"
        }
      ]
    }
  ],
  "scales": [
    {
      "name": "yscale",
      "type": "band",
      "domain": {
        "data": "table",
        "field": "dataset_name"
      },
      "range": "height",
      "padding": 0.2
    },
    {
      "name": "xscale",
      "type": "time",
      "domain": {
        "data": "table",
        "fields": ["start_date", "end_date"]
      },
      "range": "width"
    },
    {
      "name": "color",
      "type": "ordinal",
      "domain": [true, false],
      "range": ["#85C1E9", "#E74C3C"]
    }
  ],
  "axes": [
    {
      "orient": "bottom",
      "scale": "xscale",
      "title": "Time"
    },
    {
      "orient": "left",
      "scale": "yscale",
      "title": "Datasets"
    }
  ],
  "marks": [
    {
      "type": "rect",
      "from": {"data": "table"},
      "encode": {
        "enter": {
          "y": {"scale": "yscale", "field": "dataset_name"},
          "height": {"scale": "yscale", "band": 1},
          "x": {"scale": "xscale", "field": "start_date"},
          "x2": {"scale": "xscale", "field": "end_date"},
          "fill": {"scale": "color", "field": "is_available"}
        }
      }
    }
  ],
  "legends": [
    {
      "title": "Availability",
      "fill": "color",
      "orient": "right"
    }
  ]
}

The data when curling the index:

{"took":7,"timed_out":false,"_shards":{"total":1,"successful":1,"skipped":0,"failed":0},"hits":{"total":{"value":2,"relation":"eq"},"max_score":1.0,"hits":[{"_index":"availability_index","_id":"-B2Qq4sBm7775WK2vuVm","_score":1.0,"_source":{"data_product_id": "c6c029b9-37d3-4906-a554-a31f221cde31", "data_product_name": "diana-test-1", "dataset_name": "test", "is_materialized": true, "is_available": false, "start_timestamp": "2023-11-07T14:11:07.241817", "end_timestamp": "2023-11-07T14:21:07.241817"}},{"_index":"availability_index","_id":"-R2Qq4sBm7775WK2vuXR","_score":1.0,"_source":{"data_product_id": "81c9a257-b754-472f-9dcc-81f9914cb156", "data_product_name": "minioconnection", "dataset_name": "minioconnection", "is_materialized": false, "is_available": false, "start_timestamp": "2023-11-07T14:11:07.241817", "end_timestamp": "2023-11-07T14:21:07.241817"}}]}}
Any help would be highly appreciated

Missing license

Nice to see you today, @arvind.

I don't see a license anywhere. Since this is a website, though, I would just add a footer link.

Remove inline styling

In spite of having an external stylesheet, few elements have inline styles. Using inline styles has been considered as a bad practice for a long time.

P.S: I would like to self-assign this issue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.