Use mock data with ds.test

The ds.test data source is used for sample data.

Note: ds.test data sources can only be created in the source editor

You create column events and field values manually. The column and field options order are unimportant, but you must have the same number of column values as field names. ds.test is commonly structured similarly to this data source that visualizes monthly sales across multiple geographical regions.

"ds_MonthlySales": {
            "name": "ds_MonthlySales",
            "type": "ds.test",
            "options": {
                "data": {
                    "fields": [
                        {
                            "name": "month"
                        },
                        {
                            "name": "sales - americas"
                        },
                        {
                            "name": "sales - europe"
                        },
                        {
                            "name": "sales - asia"
                        },
                        {
                            "name": "sales - africa"
                        }
                    ],
                    "columns": [
                        [
                            "Jan",
                            "Feb",
                            "Mar",
                            "Apr",
                            "May",
                            "Jun",
                            "Jul",
                            "Aug",
                            "Sep",
                            "Oct",
                            "Nov",
                            "Dec"
                        ],
                        [
                            36821,
                            28683,
                            46253,
                            26723,
                            35745,
                            75265,
                            25255,
                            27467,
                            78267,
                            26581,
                            125252,
                            156212
                        ],
                        [
                            6821,
                            8683,
                            6253,
                            6723,
                            5745,
                            5265,
                            5255,
                            7467,
                            8267,
                            6581,
                            25252,
                            56212
                        ],
                        [
                            3621,
                            2683,
                            4623,
                            2623,
                            3745,
                            7565,
                            2525,
                            2747,
                            7867,
                            2581,
                            12522,
                            15612
                        ],
                        [
                            3682,
                            2863,
                            4653,
                            2723,
                            5745,
                            7526,
                            2525,
                            2767,
                            7267,
                            6581,
                            1252,
                            6212
                        ]
                    ]
                }
            }
        }

When combined with visual configurations for a column chart, the data source helps illustrate the progression of monthly sales in each region over one year.

A column chart using the ds.test data source to illustrate monthly sales over one year.