From 3d03e6f5c5eb5337e39d067ac796cdb359565276 Mon Sep 17 00:00:00 2001 From: Brandon Bertelsen Date: Wed, 27 May 2020 11:49:33 -0500 Subject: [PATCH] Updating fixtures --- man/as.data.frame.CategoricalVariable.Rd | 17 + man/with_api_fixture.Rd | 17 + .../fixtures-1-2-5/app.crunch.io/api.R | 19 + .../app.crunch.io/api/datasets/6b2eb5.json | 99 + .../api/datasets/6b2eb5/cube-a5c3da.json | 317 ++ .../datasets/6b2eb5/multitables-a17e9c-POST.R | 19 + .../api/datasets/6b2eb5/multitables.json | 14 + .../datasets/6b2eb5/multitables/7da879.json | 37 + .../multitables/7da879/export-384062-POST.R | 20 + .../api/datasets/6b2eb5/preferences.json | 7 + .../api/datasets/6b2eb5/summary-73a614.json | 16 + .../api/datasets/6b2eb5/variables-d118fa.json | 151 + .../subvariables.json | 43 + .../subvariables/0001.json | 86 + .../subvariables/0002.json | 86 + .../subvariables/0003.json | 86 + .../22dOpNBlKMRBmwvFfv087O000002.json | 89 + .../22dOpNBlKMRBmwvFfv087O000003.json | 57 + .../values-3d4982.json | 34 + .../22dOpNBlKMRBmwvFfv087O000004.json | 55 + .../values-3d4982.json | 26 + .../22dOpNBlKMRBmwvFfv087O000005.json | 55 + .../values-3d4982.json | 42 + .../22dOpNBlKMRBmwvFfv087O000007.json | 91 + .../22dOpNBlKMRBmwvFfv087O000008.json | 54 + .../values-641ef3.json | 34 + .../22dOpNBlKMRBmwvFfv087O000009.json | 54 + .../values-3d4982.json | 26 + .../6b2eb5/variables/hier-d118fa.json | 41 + .../datasets/6b2eb5/variables/weights.json | 8 + .../datasets/by_name/Example%20dataset.json | 10 +- .../app.crunch.io/api/public/login-POST.204 | 0 .../Example_dataset.json-5b3024.json | 4259 +++++++++++++++++ .../Example_dataset.json-66ae09.json | 4259 +++++++++++++++++ tests/testthat/fixtures/buildFixtures-1-2-5.R | 7 + 35 files changed, 10230 insertions(+), 5 deletions(-) create mode 100644 man/as.data.frame.CategoricalVariable.Rd create mode 100644 man/with_api_fixture.Rd create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api.R create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/cube-a5c3da.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables-a17e9c-POST.R create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879/export-384062-POST.R create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/preferences.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/summary-73a614.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables-d118fa.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/values-3d4982.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/values-3d4982.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/values-3d4982.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/values-641ef3.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/values-3d4982.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/hier-d118fa.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/weights.json create mode 100644 tests/testthat/fixtures-1-2-5/app.crunch.io/api/public/login-POST.204 create mode 100644 tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-5b3024.json create mode 100644 tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-66ae09.json diff --git a/man/as.data.frame.CategoricalVariable.Rd b/man/as.data.frame.CategoricalVariable.Rd new file mode 100644 index 00000000..ec029313 --- /dev/null +++ b/man/as.data.frame.CategoricalVariable.Rd @@ -0,0 +1,17 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/codebook.R +\name{as.data.frame.CategoricalVariable} +\alias{as.data.frame.CategoricalVariable} +\title{Categorical Variable to data.frame} +\usage{ +\method{as.data.frame}{CategoricalVariable}(x, ...) +} +\arguments{ +\item{x}{A CategoricalVariable from a crunch \link[crunch]{loadDataset}} + +\item{...}{Ignored} +} +\description{ +Manipulate categorical into a results object without hitting the tabBook +endpoint. For the purpose of creating a codebookItem. +} diff --git a/man/with_api_fixture.Rd b/man/with_api_fixture.Rd new file mode 100644 index 00000000..ed3fbd8b --- /dev/null +++ b/man/with_api_fixture.Rd @@ -0,0 +1,17 @@ +% Generated by roxygen2: do not edit by hand +% Please edit documentation in R/utils.R +\name{with_api_fixture} +\alias{with_api_fixture} +\title{crunch test wrapper} +\usage{ +with_api_fixture(fixture_path, expr) +} +\arguments{ +\item{fixture_path}{A full path to fixtures} + +\item{expr}{An expression to be run within the api fixture} +} +\description{ +Use this to wrap tests that require access to +the crunch api +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api.R b/tests/testthat/fixtures-1-2-5/app.crunch.io/api.R new file mode 100644 index 00000000..8591f8ed --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api.R @@ -0,0 +1,19 @@ +structure(list(url = "https://app.crunch.io/api/", status_code = 401L, + headers = structure(list(date = "Fri, 22 May 2020 22:57:41 GMT", + `content-type` = "application/json", `content-length` = "168", + server = "nginx", `content-encoding` = "gzip", vary = "Accept-Encoding", + allow = "GET, HEAD, OPTIONS, POST"), class = c("insensitive", + "list")), all_headers = list(list(status = 401L, version = "HTTP/2", + headers = structure(list(date = "Fri, 22 May 2020 22:57:41 GMT", + `content-type` = "application/json", `content-length` = "168", + server = "nginx", `content-encoding` = "gzip", vary = "Accept-Encoding", + allow = "GET, HEAD, OPTIONS, POST"), class = c("insensitive", + "list")))), cookies = structure(list(domain = logical(0), + flag = logical(0), path = logical(0), secure = logical(0), + expiration = structure(numeric(0), class = c("POSIXct", + "POSIXt")), name = logical(0), value = logical(0)), row.names = integer(0), class = "data.frame"), + content = charToRaw("{\"status\": \"401 Unauthorized\", \"urls\": {\"login_url\": \"https://app.crunch.io/api/public/login/\", \"password_reset_url\": \"https://app.crunch.io/api/public/password_reset/\", \"public_url\": \"https://app.crunch.io/api/public/\", \"email_change_url\": \"https://app.crunch.io/api/public/change_email/\", \"password_change_url\": \"https://app.crunch.io/api/public/password_change/\", \"collect_inquires\": \"https://app.crunch.io/api/public/inquire/\"}}"), + date = structure(1590188261, class = c("POSIXct", "POSIXt" + ), tzone = "GMT"), times = c(redirect = 0, namelookup = 2.6e-05, + connect = 2.7e-05, pretransfer = 7.4e-05, starttransfer = 0.312317, + total = 0.312469)), class = "response") diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5.json new file mode 100644 index 00000000..2df80c07 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5.json @@ -0,0 +1,99 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/", + "catalogs": { + "folders": "https://app.crunch.io/api/datasets/6b2eb5/folders/", + "users": "https://app.crunch.io/api/datasets/6b2eb5/users/", + "views": "https://app.crunch.io/api/datasets/6b2eb5/views/", + "variables": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "actions": "https://app.crunch.io/api/datasets/6b2eb5/actions/", + "boxdata": "https://app.crunch.io/api/datasets/6b2eb5/boxdata/", + "filters": "https://app.crunch.io/api/datasets/6b2eb5/filters/", + "scripts": "https://app.crunch.io/api/datasets/6b2eb5/scripts/", + "permissions": "https://app.crunch.io/api/datasets/6b2eb5/permissions/", + "batches": "https://app.crunch.io/api/datasets/6b2eb5/batches/", + "tags": "https://app.crunch.io/api/datasets/6b2eb5/tags/", + "teams": "https://app.crunch.io/api/datasets/6b2eb5/teams/", + "savepoints": "https://app.crunch.io/api/datasets/6b2eb5/savepoints/", + "multitables": "https://app.crunch.io/api/datasets/6b2eb5/multitables/", + "forks": "https://app.crunch.io/api/datasets/6b2eb5/forks/", + "decks": "https://app.crunch.io/api/datasets/6b2eb5/decks/", + "parent": "https://app.crunch.io/api/datasets/", + "project": "https://app.crunch.io/api/projects/personal/", + "variables_private": "https://app.crunch.io/api/datasets/6b2eb5/variables/private/" + }, + "fragments": { + "preferences": "https://app.crunch.io/api/datasets/6b2eb5/preferences/", + "stream": "https://app.crunch.io/api/datasets/6b2eb5/stream/", + "settings": "https://app.crunch.io/api/datasets/6b2eb5/settings/", + "exclusion": "https://app.crunch.io/api/datasets/6b2eb5/exclusion/", + "publish": "https://app.crunch.io/api/datasets/6b2eb5/publish/", + "state": "https://app.crunch.io/api/datasets/6b2eb5/state/", + "table": "https://app.crunch.io/api/datasets/6b2eb5/table/", + "pk": "https://app.crunch.io/api/datasets/6b2eb5/pk/", + "schema": "https://app.crunch.io/api/datasets/6b2eb5/schema/" + }, + "views": { + "second_order_analysis": "https://app.crunch.io/api/datasets/6b2eb5/second_order_analysis/", + "cube": "https://app.crunch.io/api/datasets/6b2eb5/cube/", + "export": "https://app.crunch.io/api/datasets/6b2eb5/export/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/summary/", + "applied_filters": "https://app.crunch.io/api/datasets/6b2eb5/filters/applied/" + }, + "description": "Detail for a given dataset", + "body": { + "maintainer": "https://app.crunch.io/api/users/0740cc/", + "current_editor": "https://app.crunch.io/api/users/0740cc/", + "creation_time": "2020-05-22T22:45:34.665000", + "streaming": "no", + "owner": "https://app.crunch.io/api/users/0740cc/", + "logo": { + "large": "https://s.crunch.io/act_app_icons/account-yougov-lrhfua-large.png", + "small": "https://s.crunch.io/act_app_icons/account-yougov-wmgadi-small.png", + "favicon": "https://s.crunch.io/act_app_icons/account-yougov-slyzix-favicon.ico" + }, + "id": "6b2eb5", + "size": { + "rows": 20, + "unfiltered_rows": 20, + "columns": 10 + }, + "palette": { + "brand": { + "message": "#722580", + "primary": "#0064a4", + "secondary": "#107f65" + } + }, + "app_settings": { + + }, + "start_date": null, + "owner_name": "Personal project for Brandon Bertelsen", + "description": "A dataset to illustrate the API", + "end_date": null, + "access_time": "2020-05-22T22:45:34.487000", + "current_editor_name": "Brandon Bertelsen", + "view_of": null, + "modification_time": "2020-05-22T22:45:37.521000", + "archived": false, + "permissions": { + "edit": true, + "view": true + }, + "account": "https://app.crunch.io/api/accounts/b7a990/", + "name": "Example dataset", + "notes": "", + "is_published": true + }, + "orders": { + "variables_weights": "https://app.crunch.io/api/datasets/6b2eb5/variables/weights/", + "variables_hier": "https://app.crunch.io/api/datasets/6b2eb5/variables/hier/", + "variables_personal": "https://app.crunch.io/api/datasets/6b2eb5/variables/personal/" + }, + "urls": { + "owner_url": "https://app.crunch.io/api/projects/bf9f4f/", + "editor_url": "https://app.crunch.io/api/users/0740cc/", + "user_url": "https://app.crunch.io/api/users/0740cc/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/cube-a5c3da.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/cube-a5c3da.json new file mode 100644 index 00000000..280567e2 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/cube-a5c3da.json @@ -0,0 +1,317 @@ +{ + "element": "shoji:view", + "self": "https://app.crunch.io/api/datasets/6b2eb5/cube/?query=%7B%22dimensions%22%3A%5B%7B%22each%22%3A%22https%3A%2F%2Fapp.crunch.io%2Fapi%2Fdatasets%2F6b2eb5%2Fvariables%2F22dOpNBlKMRBmwvFfv087O000000%2F%22%7D%2C%7B%22function%22%3A%22as_selected%22%2C%22args%22%3A%5B%7B%22variable%22%3A%22https%3A%2F%2Fapp.crunch.io%2Fapi%2Fdatasets%2F6b2eb5%2Fvariables%2F22dOpNBlKMRBmwvFfv087O000000%2F%22%7D%5D%7D%5D%2C%22measures%22%3A%7B%22count%22%3A%7B%22function%22%3A%22cube_count%22%2C%22args%22%3A%5B%5D%7D%7D%2C%22weight%22%3Anull%7D&filter=%7B%7D", + "value": { + "query": { + "measures": { + "count": { + "function": "cube_count", + "args": [ + + ] + } + }, + "dimensions": [ + { + "each": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/" + }, + { + "function": "as_selected", + "args": [ + { + "variable": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/" + } + ] + } + ], + "weight": null + }, + "query_environment": { + "filter": [ + + ] + }, + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "missing": 3, + "measures": { + "count": { + "data": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ], + "element": "crunch:cube" + } + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables-a17e9c-POST.R b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables-a17e9c-POST.R new file mode 100644 index 00000000..07912ecc --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables-a17e9c-POST.R @@ -0,0 +1,19 @@ +structure(list(url = "https://app.crunch.io/api/datasets/6b2eb5/multitables/", + status_code = 201L, headers = structure(list(date = "Fri, 22 May 2020 22:46:29 GMT", + `content-type` = "application/json;charset=utf-8", `content-length` = "0", + location = "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/", + server = "nginx", vary = "Cookie, Accept-Encoding", allow = "GET, HEAD, OPTIONS, POST", + `set-cookie` = "REDACTED"), class = c("insensitive", + "list")), all_headers = list(list(status = 201L, version = "HTTP/2", + headers = structure(list(date = "Fri, 22 May 2020 22:46:29 GMT", + `content-type` = "application/json;charset=utf-8", + `content-length` = "0", location = "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/", + server = "nginx", vary = "Cookie, Accept-Encoding", + allow = "GET, HEAD, OPTIONS, POST", `set-cookie` = "REDACTED"), class = c("insensitive", + "list")))), cookies = structure(list(domain = ".crunch.io", + flag = TRUE, path = "/", secure = FALSE, expiration = structure(1621723589, class = c("POSIXct", + "POSIXt")), name = "token", value = "REDACTED"), row.names = c(NA, + -1L), class = "data.frame"), content = charToRaw(""), date = structure(1590187589, class = c("POSIXct", + "POSIXt"), tzone = "GMT"), times = c(redirect = 0, namelookup = 2.9e-05, + connect = 2.9e-05, pretransfer = 9.4e-05, starttransfer = 9.6e-05, + total = 0.237739)), class = "response") diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables.json new file mode 100644 index 00000000..a1055e85 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables.json @@ -0,0 +1,14 @@ +{ + "element": "shoji:catalog", + "self": "https://app.crunch.io/api/datasets/6b2eb5/multitables/", + "description": "List of multitable definitions for this dataset", + "index": { + "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/": { + "is_public": false, + "team": null, + "owner_id": "https://app.crunch.io/api/users/0740cc/", + "name": "c4cae4937918ee0", + "id": "7da879" + } + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879.json new file mode 100644 index 00000000..f51321ad --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879.json @@ -0,0 +1,37 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/", + "views": { + "applied": "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/applied/", + "tabbook": "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/tabbook/", + "export": "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/export/" + }, + "description": "Detail information for one multitable definition", + "body": { + "name": "c4cae4937918ee0", + "user": "https://app.crunch.io/api/users/0740cc/", + "template": [ + { + "query": [ + { + "each": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/" + }, + { + "function": "as_selected", + "args": [ + { + "variable": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/" + } + ] + } + ] + } + ], + "team": null, + "is_public": false, + "display_settings": { + + }, + "id": "7da879" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879/export-384062-POST.R b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879/export-384062-POST.R new file mode 100644 index 00000000..1df1c1cc --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/multitables/7da879/export-384062-POST.R @@ -0,0 +1,20 @@ +structure(list(url = "https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/export/", + status_code = 202L, headers = structure(list(date = "Fri, 22 May 2020 22:46:46 GMT", + `content-type` = "application/json;charset=utf-8", `content-length` = "168", + location = "https://player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json?Signature=DyeqHU4hWaP%2B%2FFQtD%2FRCBec6gTs%3D&Expires=1590191206&AWSAccessKeyId=AKIA5IDTGVXE37N3XFXG", + server = "nginx", `content-encoding` = "gzip", vary = "Cookie, Accept-Encoding", + allow = "OPTIONS, POST", `x-timing` = "", `set-cookie` = "REDACTED"), class = c("insensitive", + "list")), all_headers = list(list(status = 202L, version = "HTTP/2", + headers = structure(list(date = "Fri, 22 May 2020 22:46:46 GMT", + `content-type` = "application/json;charset=utf-8", + `content-length` = "168", location = "https://player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json?Signature=DyeqHU4hWaP%2B%2FFQtD%2FRCBec6gTs%3D&Expires=1590191206&AWSAccessKeyId=AKIA5IDTGVXE37N3XFXG", + server = "nginx", `content-encoding` = "gzip", vary = "Cookie, Accept-Encoding", + allow = "OPTIONS, POST", `x-timing` = "", `set-cookie` = "REDACTED"), class = c("insensitive", + "list")))), cookies = structure(list(domain = ".crunch.io", + flag = TRUE, path = "/", secure = FALSE, expiration = structure(1621723606, class = c("POSIXct", + "POSIXt")), name = "token", value = "REDACTED"), row.names = c(NA, + -1L), class = "data.frame"), content = charToRaw("{\"element\": \"shoji:view\", \"self\": \"https://app.crunch.io/api/datasets/6b2eb5/multitables/7da879/export/\", \"value\": \"https://app.crunch.io/api/progress/\"}"), + date = structure(1590187606, class = c("POSIXct", "POSIXt" + ), tzone = "GMT"), times = c(redirect = 0, namelookup = 2e-05, + connect = 2.1e-05, pretransfer = 8.2e-05, starttransfer = 8.3e-05, + total = 0.669974)), class = "response") diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/preferences.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/preferences.json new file mode 100644 index 00000000..ab65e575 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/preferences.json @@ -0,0 +1,7 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/preferences/", + "body": { + "weight": null + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/summary-73a614.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/summary-73a614.json new file mode 100644 index 00000000..b3cfe6e2 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/summary-73a614.json @@ -0,0 +1,16 @@ +{ + "element": "shoji:view", + "self": "https://app.crunch.io/api/datasets/6b2eb5/summary/?filter=%7B%7D", + "value": { + "unweighted": { + "filtered": 20, + "total": 20 + }, + "variables": 10, + "weighted": { + "filtered": 20, + "total": 20 + }, + "columns": 10 + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables-d118fa.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables-d118fa.json new file mode 100644 index 00000000..4cba734a --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables-d118fa.json @@ -0,0 +1,151 @@ +{ + "element": "shoji:catalog", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/?relative=on", + "catalogs": { + "private": "https://app.crunch.io/api/datasets/6b2eb5/variables/private/" + }, + "orders": { + "personal": "https://app.crunch.io/api/datasets/6b2eb5/variables/personal/", + "weights": "https://app.crunch.io/api/datasets/6b2eb5/variables/weights/", + "hier": "https://app.crunch.io/api/datasets/6b2eb5/variables/hier/" + }, + "description": "List of Variables of this dataset", + "index": { + "22dOpNBlKMRBmwvFfv087O000007/": { + "secure": false, + "derived": false, + "id": "22dOpNBlKMRBmwvFfv087O000007", + "description": "What is your favorite pet?", + "scale": "interval", + "name": "Pet", + "notes": "", + "discarded": false, + "alias": "q1", + "hidden": false, + "type": "categorical" + }, + "22dOpNBlKMRBmwvFfv087O000006/": { + "secure": false, + "derived": false, + "subvariables": [ + "22dOpNBlKMRBmwvFfv087O000006/subvariables/0001/", + "22dOpNBlKMRBmwvFfv087O000006/subvariables/0002/" + ], + "id": "22dOpNBlKMRBmwvFfv087O000006", + "description": "Name the kinds of pets you have at these locations.", + "subvariables_catalog": "22dOpNBlKMRBmwvFfv087O000006/subvariables/", + "scale": "interval", + "name": "Pets by location", + "notes": "", + "discarded": false, + "alias": "petloc", + "hidden": false, + "type": "categorical_array" + }, + "22dOpNBlKMRBmwvFfv087O000008/": { + "discarded": false, + "alias": "q3", + "secure": false, + "name": "Pet name", + "id": "22dOpNBlKMRBmwvFfv087O000008", + "type": "text", + "notes": "", + "derived": false, + "hidden": false, + "description": "What is your favorite pet's maiden name?" + }, + "22dOpNBlKMRBmwvFfv087O000009/": { + "secure": false, + "derived": false, + "rollup_resolution": null, + "id": "22dOpNBlKMRBmwvFfv087O000009", + "description": "", + "name": "Wave", + "resolution": "D", + "notes": "", + "discarded": false, + "alias": "wave", + "hidden": false, + "type": "datetime" + }, + "22dOpNBlKMRBmwvFfv087O000000/": { + "secure": false, + "derived": false, + "subvariables": [ + "22dOpNBlKMRBmwvFfv087O000000/subvariables/0001/", + "22dOpNBlKMRBmwvFfv087O000000/subvariables/0002/", + "22dOpNBlKMRBmwvFfv087O000000/subvariables/0003/" + ], + "id": "22dOpNBlKMRBmwvFfv087O000000", + "description": "Do you have any of these animals as pets? Please select all that apply.", + "subvariables_catalog": "22dOpNBlKMRBmwvFfv087O000000/subvariables/", + "uniform_basis": false, + "name": "All pets owned", + "notes": "", + "discarded": false, + "alias": "allpets", + "hidden": false, + "type": "multiple_response" + }, + "22dOpNBlKMRBmwvFfv087O000001/": { + "discarded": true, + "alias": "caseid", + "secure": false, + "name": "Case ID", + "id": "22dOpNBlKMRBmwvFfv087O000001", + "type": "numeric", + "notes": "", + "derived": false, + "hidden": true, + "description": "" + }, + "22dOpNBlKMRBmwvFfv087O000003/": { + "discarded": false, + "alias": "ndogs", + "secure": false, + "name": "Number of dogs", + "id": "22dOpNBlKMRBmwvFfv087O000003", + "type": "numeric", + "notes": "", + "derived": false, + "hidden": false, + "description": "" + }, + "22dOpNBlKMRBmwvFfv087O000002/": { + "discarded": false, + "alias": "country", + "secure": false, + "name": "Country", + "id": "22dOpNBlKMRBmwvFfv087O000002", + "type": "categorical", + "notes": "", + "derived": false, + "hidden": false, + "description": "" + }, + "22dOpNBlKMRBmwvFfv087O000004/": { + "discarded": false, + "alias": "ndogs_a", + "secure": false, + "name": "Number of dogs -- With papers", + "id": "22dOpNBlKMRBmwvFfv087O000004", + "type": "numeric", + "notes": "", + "derived": false, + "hidden": false, + "description": "How many dogs do you have?" + }, + "22dOpNBlKMRBmwvFfv087O000005/": { + "discarded": false, + "alias": "ndogs_b", + "secure": false, + "name": "Number of dogs -- Mutts", + "id": "22dOpNBlKMRBmwvFfv087O000005", + "type": "numeric", + "notes": "", + "derived": false, + "hidden": false, + "description": "How many dogs do you have?" + } + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables.json new file mode 100644 index 00000000..36c2501e --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables.json @@ -0,0 +1,43 @@ +{ + "element": "shoji:catalog", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/", + "description": "Contains the subvariables for this array variable.", + "index": { + "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002/": { + "discarded": false, + "alias": "allpets_2", + "secure": false, + "name": "Dog", + "id": "0002", + "type": "categorical", + "notes": "", + "derived": false, + "hidden": false, + "description": "" + }, + "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003/": { + "discarded": false, + "alias": "allpets_3", + "secure": false, + "name": "Bird", + "id": "0003", + "type": "categorical", + "notes": "", + "derived": false, + "hidden": false, + "description": "" + }, + "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001/": { + "discarded": false, + "alias": "allpets_1", + "secure": false, + "name": "Cat", + "id": "0001", + "type": "categorical", + "notes": "", + "derived": false, + "hidden": false, + "description": "" + } + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001.json new file mode 100644 index 00000000..faa22507 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001.json @@ -0,0 +1,86 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001/", + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001/frequencies/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001/values/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0001/summary/" + }, + "body": { + "secure": false, + "name": "Cat", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1, + "skipped": 8, + "not asked": 9 + }, + "private": false, + "discarded": false, + "alias": "allpets_1", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "show_numeric_values": false, + "include_missing": false, + "show_counts": false, + "column_width": null, + "include_noneoftheabove": false + }, + "type": "categorical", + "id": "0001", + "categories": [ + { + "numeric_value": null, + "selected": false, + "id": 2, + "missing": false, + "name": "not selected" + }, + { + "numeric_value": null, + "selected": true, + "id": 1, + "missing": false, + "name": "selected" + }, + { + "numeric_value": 9, + "id": 9, + "name": "not asked", + "missing": true + }, + { + "numeric_value": 8, + "id": 8, + "name": "skipped", + "missing": true + }, + { + "numeric_value": null, + "id": -1, + "name": "No Data", + "missing": true + } + ], + "description": "" + }, + "description": "Details for a given Variable", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/" + }, + "fragments": { + "variable": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002.json new file mode 100644 index 00000000..af8577cc --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002.json @@ -0,0 +1,86 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002/", + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002/frequencies/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002/values/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0002/summary/" + }, + "body": { + "secure": false, + "name": "Dog", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1, + "skipped": 8, + "not asked": 9 + }, + "private": false, + "discarded": false, + "alias": "allpets_2", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "show_numeric_values": false, + "include_missing": false, + "show_counts": false, + "column_width": null, + "include_noneoftheabove": false + }, + "type": "categorical", + "id": "0002", + "categories": [ + { + "numeric_value": null, + "selected": false, + "id": 2, + "missing": false, + "name": "not selected" + }, + { + "numeric_value": null, + "selected": true, + "id": 1, + "missing": false, + "name": "selected" + }, + { + "numeric_value": 9, + "id": 9, + "name": "not asked", + "missing": true + }, + { + "numeric_value": 8, + "id": 8, + "name": "skipped", + "missing": true + }, + { + "numeric_value": null, + "id": -1, + "name": "No Data", + "missing": true + } + ], + "description": "" + }, + "description": "Details for a given Variable", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/" + }, + "fragments": { + "variable": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003.json new file mode 100644 index 00000000..4ff0c604 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003.json @@ -0,0 +1,86 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003/", + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003/frequencies/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003/values/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/0003/summary/" + }, + "body": { + "secure": false, + "name": "Bird", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1, + "skipped": 8, + "not asked": 9 + }, + "private": false, + "discarded": false, + "alias": "allpets_3", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "show_numeric_values": false, + "include_missing": false, + "show_counts": false, + "column_width": null, + "include_noneoftheabove": false + }, + "type": "categorical", + "id": "0003", + "categories": [ + { + "numeric_value": null, + "selected": false, + "id": 2, + "missing": false, + "name": "not selected" + }, + { + "numeric_value": null, + "selected": true, + "id": 1, + "missing": false, + "name": "selected" + }, + { + "numeric_value": 9, + "id": 9, + "name": "not asked", + "missing": true + }, + { + "numeric_value": 8, + "id": 8, + "name": "skipped", + "missing": true + }, + { + "numeric_value": null, + "id": -1, + "name": "No Data", + "missing": true + } + ], + "description": "" + }, + "description": "Details for a given Variable", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/subvariables/" + }, + "fragments": { + "variable": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000000/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002.json new file mode 100644 index 00000000..6af97bfa --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002.json @@ -0,0 +1,89 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002/", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "folder": "https://app.crunch.io/api/datasets/6b2eb5/folders/8cef7d/" + }, + "fragments": { + "user_settings": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002/user_settings/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002/frequencies/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002/summary/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002/values/", + "cast": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000002/cast/" + }, + "body": { + "secure": false, + "name": "Country", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1 + }, + "private": false, + "discarded": false, + "alias": "country", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "show_numeric_values": false, + "include_missing": false, + "show_counts": false, + "column_width": null + }, + "type": "categorical", + "id": "22dOpNBlKMRBmwvFfv087O000002", + "categories": [ + { + "numeric_value": null, + "missing": false, + "id": 1, + "name": "Argentina" + }, + { + "numeric_value": null, + "missing": false, + "id": 2, + "name": "Australia" + }, + { + "numeric_value": null, + "missing": false, + "id": 3, + "name": "Austria" + }, + { + "numeric_value": null, + "missing": false, + "id": 4, + "name": "Belgium" + }, + { + "numeric_value": null, + "missing": false, + "id": 5, + "name": "Brazil" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ], + "description": "" + }, + "description": "Details for a given Variable", + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003.json new file mode 100644 index 00000000..1dcd35b0 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003.json @@ -0,0 +1,57 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "folder": "https://app.crunch.io/api/datasets/6b2eb5/folders/2ff8b8/" + }, + "fragments": { + "missing_rules": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/missing_rules/", + "user_settings": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/user_settings/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/frequencies/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/summary/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/values/", + "cast": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/cast/" + }, + "body": { + "secure": false, + "name": "Number of dogs", + "format": { + "data": { + "digits": 2 + }, + "summary": { + "digits": 2 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1, + "skipped": 1, + "not asked": 2 + }, + "private": false, + "discarded": false, + "alias": "ndogs", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "column_width": null + }, + "type": "numeric", + "id": "22dOpNBlKMRBmwvFfv087O000003", + "categories": [ + + ], + "description": "" + }, + "description": "Details for a given Variable", + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/values-3d4982.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/values-3d4982.json new file mode 100644 index 00000000..4b45b3a5 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/values-3d4982.json @@ -0,0 +1,34 @@ +{ + "element": "shoji:view", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000003/values/?filter=%7B%7D&offset=0&limit=100000", + "value": [ + 1.0, + { + "?": 2 + }, + 2.0, + 3.0, + 1.0, + 2.0, + 2.0, + 3.0, + 2.0, + 2.0, + 2.0, + { + "?": -1 + }, + 3.0, + 0.0, + 6.0, + 1.0, + { + "?": 2 + }, + 0.0, + { + "?": 1 + }, + 2.0 + ] +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004.json new file mode 100644 index 00000000..3e2997e4 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004.json @@ -0,0 +1,55 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "folder": "https://app.crunch.io/api/datasets/6b2eb5/folders/6bab07/" + }, + "fragments": { + "missing_rules": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/missing_rules/", + "user_settings": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/user_settings/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/frequencies/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/summary/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/values/", + "cast": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/cast/" + }, + "body": { + "secure": false, + "name": "Number of dogs -- With papers", + "format": { + "data": { + "digits": 2 + }, + "summary": { + "digits": 2 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1 + }, + "private": false, + "discarded": false, + "alias": "ndogs_a", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "column_width": null + }, + "type": "numeric", + "id": "22dOpNBlKMRBmwvFfv087O000004", + "categories": [ + + ], + "description": "How many dogs do you have?" + }, + "description": "Details for a given Variable", + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/values-3d4982.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/values-3d4982.json new file mode 100644 index 00000000..e4281838 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/values-3d4982.json @@ -0,0 +1,26 @@ +{ + "element": "shoji:view", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000004/values/?filter=%7B%7D&offset=0&limit=100000", + "value": [ + 1.0, + 1.0, + 1.0, + 0.0, + 4.0, + 0.0, + 3.0, + 3.0, + 1.0, + 5.0, + 0.0, + 1.0, + 2.0, + 3.0, + 3.0, + 2.0, + 2.0, + 1.0, + 4.0, + 2.0 + ] +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005.json new file mode 100644 index 00000000..b1f407b0 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005.json @@ -0,0 +1,55 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "folder": "https://app.crunch.io/api/datasets/6b2eb5/folders/6bab07/" + }, + "fragments": { + "missing_rules": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/missing_rules/", + "user_settings": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/user_settings/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/frequencies/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/summary/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/values/", + "cast": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/cast/" + }, + "body": { + "secure": false, + "name": "Number of dogs -- Mutts", + "format": { + "data": { + "digits": 2 + }, + "summary": { + "digits": 2 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1 + }, + "private": false, + "discarded": false, + "alias": "ndogs_b", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "column_width": null + }, + "type": "numeric", + "id": "22dOpNBlKMRBmwvFfv087O000005", + "categories": [ + + ], + "description": "How many dogs do you have?" + }, + "description": "Details for a given Variable", + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/values-3d4982.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/values-3d4982.json new file mode 100644 index 00000000..d1e680c7 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/values-3d4982.json @@ -0,0 +1,42 @@ +{ + "element": "shoji:view", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000005/values/?filter=%7B%7D&offset=0&limit=100000", + "value": [ + 0.0, + 2.0, + 2.0, + { + "?": -1 + }, + { + "?": -1 + }, + 3.0, + 1.0, + { + "?": -1 + }, + 1.0, + { + "?": -1 + }, + 0.0, + { + "?": -1 + }, + { + "?": -1 + }, + { + "?": -1 + }, + 2.0, + 1.0, + 3.0, + { + "?": -1 + }, + 2.0, + 2.0 + ] +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007.json new file mode 100644 index 00000000..62b8496e --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007.json @@ -0,0 +1,91 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007/", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "folder": "https://app.crunch.io/api/datasets/6b2eb5/folders/f6f43b/" + }, + "fragments": { + "user_settings": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007/user_settings/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007/frequencies/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007/summary/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007/values/", + "cast": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000007/cast/" + }, + "body": { + "secure": false, + "name": "Pet", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1, + "Skipped": 8, + "Not Asked": 9 + }, + "private": false, + "discarded": false, + "alias": "q1", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "show_numeric_values": false, + "include_missing": false, + "show_counts": false, + "column_width": null + }, + "type": "categorical", + "id": "22dOpNBlKMRBmwvFfv087O000007", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ], + "description": "What is your favorite pet?" + }, + "description": "Details for a given Variable", + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008.json new file mode 100644 index 00000000..5939110d --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008.json @@ -0,0 +1,54 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "folder": "https://app.crunch.io/api/datasets/6b2eb5/folders/6db4c0/" + }, + "fragments": { + "missing_rules": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/missing_rules/", + "user_settings": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/user_settings/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/frequencies/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/summary/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/values/", + "cast": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/cast/" + }, + "body": { + "secure": false, + "name": "Pet name", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1, + "Not asked": 1 + }, + "private": false, + "discarded": false, + "alias": "q3", + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "show_counts": true, + "column_width": null + }, + "type": "text", + "id": "22dOpNBlKMRBmwvFfv087O000008", + "categories": [ + + ], + "description": "What is your favorite pet's maiden name?" + }, + "description": "Details for a given Variable", + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/values-641ef3.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/values-641ef3.json new file mode 100644 index 00000000..0dfede58 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/values-641ef3.json @@ -0,0 +1,34 @@ +{ + "element": "shoji:view", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000008/values/?filter=%7B%7D&offset=0&limit=5000", + "value": [ + "Jasmine", + "Clyde", + "Geoffrey", + "Spike", + "Zeus", + "Teddy", + "Ali", + "Hugo", + "Snoopy", + "Lady", + "Biscuit", + { + "?": 1 + }, + "Daisy", + "Doug", + { + "?": 1 + }, + "Fluffy", + { + "?": 1 + }, + { + "?": 1 + }, + "Felix", + "Rocky" + ] +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009.json new file mode 100644 index 00000000..cb1e9e55 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009.json @@ -0,0 +1,54 @@ +{ + "element": "shoji:entity", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/", + "catalogs": { + "parent": "https://app.crunch.io/api/datasets/6b2eb5/variables/", + "folder": "https://app.crunch.io/api/datasets/6b2eb5/folders/8cef7d/" + }, + "fragments": { + "missing_rules": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/missing_rules/", + "user_settings": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/user_settings/", + "dataset": "https://app.crunch.io/api/datasets/6b2eb5/" + }, + "views": { + "frequencies": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/frequencies/", + "summary": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/summary/", + "values": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/values/", + "cast": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/cast/" + }, + "body": { + "secure": false, + "name": "Wave", + "format": { + "data": "%Y-%m-%d", + "summary": "%Y-%m-%d" + }, + "resolution": "D", + "notes": "", + "derived": false, + "missing_reasons": { + "No Data": -1 + }, + "private": false, + "discarded": false, + "alias": "wave", + "rollup_resolution": null, + "dataset_id": "6b2eb5", + "owner": null, + "hidden": false, + "view": { + "rollup_resolution": null, + "column_width": null + }, + "type": "datetime", + "id": "22dOpNBlKMRBmwvFfv087O000009", + "categories": [ + + ], + "description": "" + }, + "description": "Details for a given Variable", + "urls": { + "dataset_url": "https://app.crunch.io/api/datasets/6b2eb5/" + } +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/values-3d4982.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/values-3d4982.json new file mode 100644 index 00000000..8789bdeb --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/values-3d4982.json @@ -0,0 +1,26 @@ +{ + "element": "shoji:view", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/22dOpNBlKMRBmwvFfv087O000009/values/?filter=%7B%7D&offset=0&limit=100000", + "value": [ + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2014-12-01", + "2015-01-01", + "2015-01-01", + "2015-01-01", + "2015-01-01", + "2015-01-01", + "2015-01-01", + "2015-01-01", + "2015-01-01", + "2015-01-01", + "2015-01-01" + ] +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/hier-d118fa.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/hier-d118fa.json new file mode 100644 index 00000000..49d2186f --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/hier-d118fa.json @@ -0,0 +1,41 @@ +{ + "element": "shoji:order", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/hier/?relative=on", + "description": "Hierarchical order from folder structure of dataset variables", + "graph": [ + { + "Key Pet Indicators": [ + "../22dOpNBlKMRBmwvFfv087O000000/", + "../22dOpNBlKMRBmwvFfv087O000007/", + "../22dOpNBlKMRBmwvFfv087O000006/" + ] + }, + { + "Dog Metrics": [ + "../22dOpNBlKMRBmwvFfv087O000003/", + { + "Number of dogs by type": [ + "../22dOpNBlKMRBmwvFfv087O000004/", + "../22dOpNBlKMRBmwvFfv087O000005/" + ] + } + ] + }, + { + "Details": [ + "../22dOpNBlKMRBmwvFfv087O000008/" + ] + }, + { + "Dimensions": [ + "../22dOpNBlKMRBmwvFfv087O000002/", + "../22dOpNBlKMRBmwvFfv087O000009/" + ] + }, + { + "__hidden__": [ + "../22dOpNBlKMRBmwvFfv087O000001/" + ] + } + ] +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/weights.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/weights.json new file mode 100644 index 00000000..f06bb76b --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/6b2eb5/variables/weights.json @@ -0,0 +1,8 @@ +{ + "element": "shoji:order", + "self": "https://app.crunch.io/api/datasets/6b2eb5/variables/weights/", + "description": "Order of the weight variables for this dataset", + "graph": [ + + ] +} diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/by_name/Example%20dataset.json b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/by_name/Example%20dataset.json index aa652bb6..06e6fdaf 100644 --- a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/by_name/Example%20dataset.json +++ b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/datasets/by_name/Example%20dataset.json @@ -3,7 +3,7 @@ "self": "https://app.crunch.io/api/datasets/by_name/Example%20dataset/", "description": "Datasets with a given name ", "index": { - "https://app.crunch.io/api/datasets/e6d1e7/": { + "https://app.crunch.io/api/datasets/6b2eb5/": { "size": { "rows": 20, "unfiltered_rows": 20, @@ -17,18 +17,18 @@ "streaming": "no", "owner_id": "https://app.crunch.io/api/users/0740cc/", "current_editor": "https://app.crunch.io/api/users/0740cc/", - "creation_time": "2020-05-20T23:56:00.471000+00:00", + "creation_time": "2020-05-22T22:45:34.665000+00:00", "archived": false, "view_of": null, "start_date": null, - "modification_time": "2020-05-20T23:56:02.824000+00:00", - "access_time": "2020-05-20T23:56:00.283000+00:00", + "modification_time": "2020-05-22T22:45:37.521000+00:00", + "access_time": "2020-05-22T22:45:34.487000+00:00", "permissions": { "edit": true, "view": true }, "is_published": true, - "id": "e6d1e7", + "id": "6b2eb5", "description": "A dataset to illustrate the API" } } diff --git a/tests/testthat/fixtures-1-2-5/app.crunch.io/api/public/login-POST.204 b/tests/testthat/fixtures-1-2-5/app.crunch.io/api/public/login-POST.204 new file mode 100644 index 00000000..e69de29b diff --git a/tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-5b3024.json b/tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-5b3024.json new file mode 100644 index 00000000..ecd6d079 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-5b3024.json @@ -0,0 +1,4259 @@ +{ + "meta": { + "multitable_id": "7da879", + "user_id": "0740cc", + "doc_layout": { + "toc": false, + "variable_sheets": "many_sheets", + "measure_sheets": "wide" + }, + "dataset": { + "name": "Example dataset", + "notes": "", + "min_base_size": { + "suppress": true, + "size": 0 + }, + "population_size": null, + "dataset_id": "6b2eb5", + "description": "A dataset to illustrate the API" + }, + "template": [ + { + "query": [ + { + "each": "22dOpNBlKMRBmwvFfv087O000000" + }, + { + "function": "as_selected", + "args": [ + { + "variable": "22dOpNBlKMRBmwvFfv087O000000" + } + ] + } + ] + } + ], + "analyses": [ + { + "name": "All pets owned", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + }, + { + "name": "Pet", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + }, + { + "name": "Pets by location", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + }, + { + "name": "Number of dogs", + "weight": null, + "title": "Number of dogs", + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null + }, + { + "name": "Number of dogs -- With papers", + "weight": null, + "title": "Number of dogs -- With papers", + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null + }, + { + "name": "Number of dogs -- Mutts", + "weight": null, + "title": "Number of dogs -- Mutts", + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null + }, + { + "name": "Country", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + } + ] + }, + "sheets": [ + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 4, + 0, + 0, + 0, + 0, + 4, + 1, + 0, + 3, + 0, + 4, + 0, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 12, + 4, + 2, + 6, + 3, + 5, + 4, + 0, + 1, + 4, + 5, + 0, + 0, + 3, + 1, + 1, + 0, + 1, + 2, + 0, + 3, + 0, + 1, + 1, + 1, + 4, + 2, + 6, + 0, + 0, + 12, + 1, + 4, + 7, + 1, + 1, + 3, + 3, + 1, + 1, + 5, + 0, + 0, + 0, + 1, + 5, + 1, + 1, + 4, + 0, + 6, + 0, + 3, + 2, + 4, + 1, + 1, + 7, + 0, + 0, + 9 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 0, + 0, + 0, + 0, + 4, + 1, + 0, + 3, + 0, + 4, + 0, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 12, + 4, + 2, + 6, + 3, + 5, + 4, + 0, + 1, + 4, + 5, + 0, + 0, + 3, + 1, + 1, + 0, + 1, + 2, + 0, + 3, + 0, + 1, + 1, + 1, + 4, + 2, + 6, + 0, + 0, + 12, + 1, + 4, + 7, + 1, + 1, + 3, + 3, + 1, + 1, + 5, + 0, + 0, + 0, + 1, + 5, + 1, + 1, + 4, + 0, + 6, + 0, + 3, + 2, + 4, + 1, + 1, + 7, + 0, + 0, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "description": "What is your favorite pet?", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Pet", + "alias": "q1", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 6, + 4, + 3, + 3, + 4, + 0 + ], + "n_missing": 7, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 6, + 4, + 3, + 3, + 4, + 0 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "description": "What is your favorite pet?", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Pet", + "alias": "q1", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 0, + 0, + 6, + 2, + 2, + 2, + 2, + 3, + 1, + 1, + 1, + 2, + 1, + 0, + 3, + 1, + 0, + 3, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 1, + 1, + 0, + 0, + 3, + 0, + 2, + 1, + 1, + 2, + 1, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "n_missing": 10, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 0, + 0, + 6, + 2, + 2, + 2, + 2, + 3, + 1, + 1, + 1, + 2, + 1, + 0, + 3, + 1, + 0, + 3, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 1, + 1, + 0, + 0, + 3, + 0, + 2, + 1, + 1, + 2, + 1, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + }, + "name": "Pets by location" + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "petloc_home", + "name": "Home" + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "petloc_work", + "name": "Work" + }, + "id": "0002" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "name": "Pets by location", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 5, + 3, + 3, + 4, + 5, + 0, + 6, + 4, + 6, + 3, + 1, + 0 + ], + "n_missing": 2, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 5, + 3, + 3, + 4, + 5, + 0, + 6, + 4, + 6, + 3, + 1, + 0 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + }, + "name": "Pets by location" + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "petloc_home", + "name": "Home" + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "petloc_work", + "name": "Work" + }, + "id": "0002" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "name": "Pets by location", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 0, + 1, + 4, + 1, + 2, + 2, + 2, + 0, + 3, + 0, + 0, + 3, + 3, + 0, + 0, + 1, + 1, + 1, + 0, + 1, + 2, + 1, + 1, + 1, + 1, + 2, + 0, + 2, + 1, + 1, + 0, + 0, + 4, + 1, + 1, + 2, + 2, + 1, + 2, + 0, + 0, + 5, + 0, + 2, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 4, + 1, + 0, + 5, + 2, + 2, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 2, + 3, + 2, + 1, + 3, + 1, + 3, + 2, + 0, + 0, + 3, + 1, + 1, + 1, + 1, + 0, + 2, + 1, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "n_missing": 4, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 0, + 1, + 4, + 1, + 2, + 2, + 2, + 0, + 3, + 0, + 0, + 3, + 3, + 0, + 0, + 1, + 1, + 1, + 0, + 1, + 2, + 1, + 1, + 1, + 1, + 2, + 0, + 2, + 1, + 1, + 0, + 0, + 4, + 1, + 1, + 2, + 2, + 1, + 2, + 0, + 0, + 5, + 0, + 2, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 4, + 1, + 0, + 5, + 2, + 2, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 2, + 3, + 2, + 1, + 3, + 1, + 3, + 2, + 0, + 0, + 3, + 1, + 1, + 1, + 1, + 0, + 2, + 1, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + + ], + "measures": { + "mean": { + "data": [ + 2.0 + ], + "n_missing": 4, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 20 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "mean": { + "data": [ + 2.0, + 1.75, + 2.1111111111, + 3.0, + 2.0, + 1.7272727273, + 3.0, + 1.75, + 1.7777777778 + ], + "n_missing": 7, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + + ], + "measures": { + "mean": { + "data": [ + 1.95 + ], + "n_missing": 0, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 20 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "mean": { + "data": [ + 1.5, + 2.5, + 1.9166666667, + 1.8, + 2.0, + 2.0, + 2.2, + 1.0, + 2.4444444444 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + + ], + "measures": { + "mean": { + "data": [ + 1.5833333333 + ], + "n_missing": 8, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 20 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "mean": { + "data": [ + 1.3333333333, + 0.6666666667, + 2.1666666667, + 1.75, + 1.6666666667, + 1.4, + 1.5, + 2.0, + 1.25 + ], + "n_missing": 8, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "description": "", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Country", + "alias": "country", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": null, + "missing": false, + "id": 1, + "name": "Argentina" + }, + { + "numeric_value": null, + "missing": false, + "id": 2, + "name": "Australia" + }, + { + "numeric_value": null, + "missing": false, + "id": 3, + "name": "Austria" + }, + { + "numeric_value": null, + "missing": false, + "id": 4, + "name": "Belgium" + }, + { + "numeric_value": null, + "missing": false, + "id": 5, + "name": "Brazil" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 4, + 4, + 4, + 4, + 4, + 0 + ], + "n_missing": 0, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 4, + 4, + 4, + 0 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "description": "", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Country", + "alias": "country", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": null, + "missing": false, + "id": 1, + "name": "Argentina" + }, + { + "numeric_value": null, + "missing": false, + "id": 2, + "name": "Australia" + }, + { + "numeric_value": null, + "missing": false, + "id": 3, + "name": "Austria" + }, + { + "numeric_value": null, + "missing": false, + "id": 4, + "name": "Belgium" + }, + { + "numeric_value": null, + "missing": false, + "id": 5, + "name": "Brazil" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 1, + 2, + 1, + 1, + 0, + 3, + 1, + 2, + 1, + 0, + 1, + 3, + 2, + 2, + 0, + 1, + 2, + 1, + 1, + 0, + 3, + 0, + 0, + 4, + 0, + 2, + 2, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 1, + 0, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 1, + 2, + 1, + 1, + 0, + 3, + 1, + 2, + 1, + 0, + 1, + 3, + 2, + 2, + 0, + 1, + 2, + 1, + 1, + 0, + 3, + 0, + 0, + 4, + 0, + 2, + 2, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 1, + 0, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ] + } + } + ] + } + ] +} diff --git a/tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-66ae09.json b/tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-66ae09.json new file mode 100644 index 00000000..ecd6d079 --- /dev/null +++ b/tests/testthat/fixtures-1-2-5/player-crunch-io.s3.amazonaws.com/export/tabbooks/export_tabbook%3A6b2eb5%249a4e74/Example_dataset.json-66ae09.json @@ -0,0 +1,4259 @@ +{ + "meta": { + "multitable_id": "7da879", + "user_id": "0740cc", + "doc_layout": { + "toc": false, + "variable_sheets": "many_sheets", + "measure_sheets": "wide" + }, + "dataset": { + "name": "Example dataset", + "notes": "", + "min_base_size": { + "suppress": true, + "size": 0 + }, + "population_size": null, + "dataset_id": "6b2eb5", + "description": "A dataset to illustrate the API" + }, + "template": [ + { + "query": [ + { + "each": "22dOpNBlKMRBmwvFfv087O000000" + }, + { + "function": "as_selected", + "args": [ + { + "variable": "22dOpNBlKMRBmwvFfv087O000000" + } + ] + } + ] + } + ], + "analyses": [ + { + "name": "All pets owned", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + }, + { + "name": "Pet", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + }, + { + "name": "Pets by location", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + }, + { + "name": "Number of dogs", + "weight": null, + "title": "Number of dogs", + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null + }, + { + "name": "Number of dogs -- With papers", + "weight": null, + "title": "Number of dogs -- With papers", + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null + }, + { + "name": "Number of dogs -- Mutts", + "weight": null, + "title": "Number of dogs -- Mutts", + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null + }, + { + "name": "Country", + "weight": null, + "title": null, + "format": { + "show_empty": false, + "decimal_places": 0, + "pval_colors": false + }, + "measures": [ + "col_percent" + ], + "page_layout": { + "rows": { + "alias": false, + "notes": false, + "description": true, + "bottom": [ + + ] + }, + "columns": { + "alias": false, + "notes": false, + "right": [ + + ], + "description": false, + "merge_ranges": true + } + }, + "filters": null, + "notes": "" + } + ] + }, + "sheets": [ + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 4, + 0, + 0, + 0, + 0, + 4, + 1, + 0, + 3, + 0, + 4, + 0, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 12, + 4, + 2, + 6, + 3, + 5, + 4, + 0, + 1, + 4, + 5, + 0, + 0, + 3, + 1, + 1, + 0, + 1, + 2, + 0, + 3, + 0, + 1, + 1, + 1, + 4, + 2, + 6, + 0, + 0, + 12, + 1, + 4, + 7, + 1, + 1, + 3, + 3, + 1, + 1, + 5, + 0, + 0, + 0, + 1, + 5, + 1, + 1, + 4, + 0, + 6, + 0, + 3, + 2, + 4, + 1, + 1, + 7, + 0, + 0, + 9 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 0, + 0, + 0, + 0, + 4, + 1, + 0, + 3, + 0, + 4, + 0, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 12, + 4, + 2, + 6, + 3, + 5, + 4, + 0, + 1, + 4, + 5, + 0, + 0, + 3, + 1, + 1, + 0, + 1, + 2, + 0, + 3, + 0, + 1, + 1, + 1, + 4, + 2, + 6, + 0, + 0, + 12, + 1, + 4, + 7, + 1, + 1, + 3, + 3, + 1, + 1, + 5, + 0, + 0, + 0, + 1, + 5, + 1, + 1, + 4, + 0, + 6, + 0, + 3, + 2, + 4, + 1, + 1, + 7, + 0, + 0, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "description": "What is your favorite pet?", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Pet", + "alias": "q1", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 6, + 4, + 3, + 3, + 4, + 0 + ], + "n_missing": 7, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 6, + 4, + 3, + 3, + 4, + 0 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "description": "What is your favorite pet?", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Pet", + "alias": "q1", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 0, + 0, + 6, + 2, + 2, + 2, + 2, + 3, + 1, + 1, + 1, + 2, + 1, + 0, + 3, + 1, + 0, + 3, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 1, + 1, + 0, + 0, + 3, + 0, + 2, + 1, + 1, + 2, + 1, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "n_missing": 10, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 0, + 0, + 6, + 2, + 2, + 2, + 2, + 3, + 1, + 1, + 1, + 2, + 1, + 0, + 3, + 1, + 0, + 3, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 0, + 2, + 1, + 1, + 1, + 0, + 0, + 3, + 0, + 2, + 1, + 1, + 2, + 1, + 1, + 1, + 2, + 1, + 1, + 2, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + }, + "name": "Pets by location" + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "petloc_home", + "name": "Home" + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "petloc_work", + "name": "Work" + }, + "id": "0002" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "name": "Pets by location", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 5, + 3, + 3, + 4, + 5, + 0, + 6, + 4, + 6, + 3, + 1, + 0 + ], + "n_missing": 2, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 5, + 3, + 3, + 4, + 5, + 0, + 6, + 4, + 6, + 3, + 1, + 0 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + }, + "name": "Pets by location" + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "petloc_home", + "name": "Home" + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "petloc_work", + "name": "Work" + }, + "id": "0002" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "references": { + "uniform_basis": false, + "description": "Name the kinds of pets you have at these locations.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "petloc_home", + "name": "Home" + }, + { + "alias": "petloc_work", + "name": "Work" + } + ], + "notes": "", + "name": "Pets by location", + "alias": "petloc", + "view": { + "show_counts": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "missing": false, + "id": 1, + "name": "Cat" + }, + { + "numeric_value": 2, + "missing": false, + "id": 2, + "name": "Dog" + }, + { + "numeric_value": 3, + "missing": false, + "id": 3, + "name": "Bird" + }, + { + "numeric_value": 8, + "missing": true, + "id": 8, + "name": "Skipped" + }, + { + "numeric_value": 9, + "missing": true, + "id": 9, + "name": "Not Asked" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 0, + 1, + 4, + 1, + 2, + 2, + 2, + 0, + 3, + 0, + 0, + 3, + 3, + 0, + 0, + 1, + 1, + 1, + 0, + 1, + 2, + 1, + 1, + 1, + 1, + 2, + 0, + 2, + 1, + 1, + 0, + 0, + 4, + 1, + 1, + 2, + 2, + 1, + 2, + 0, + 0, + 5, + 0, + 2, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 4, + 1, + 0, + 5, + 2, + 2, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 2, + 3, + 2, + 1, + 3, + 1, + 3, + 2, + 0, + 0, + 3, + 1, + 1, + 1, + 1, + 0, + 2, + 1, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "n_missing": 4, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 0, + 1, + 4, + 1, + 2, + 2, + 2, + 0, + 3, + 0, + 0, + 3, + 3, + 0, + 0, + 1, + 1, + 1, + 0, + 1, + 2, + 1, + 1, + 1, + 1, + 2, + 0, + 2, + 1, + 1, + 0, + 0, + 4, + 1, + 1, + 2, + 2, + 1, + 2, + 0, + 0, + 5, + 0, + 2, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 1, + 4, + 1, + 0, + 5, + 2, + 2, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 1, + 2, + 1, + 2, + 3, + 2, + 1, + 3, + 1, + 3, + 2, + 0, + 0, + 3, + 1, + 1, + 1, + 1, + 0, + 2, + 1, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + + ], + "measures": { + "mean": { + "data": [ + 2.0 + ], + "n_missing": 4, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 20 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "mean": { + "data": [ + 2.0, + 1.75, + 2.1111111111, + 3.0, + 2.0, + 1.7272727273, + 3.0, + 1.75, + 1.7777777778 + ], + "n_missing": 7, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + + ], + "measures": { + "mean": { + "data": [ + 1.95 + ], + "n_missing": 0, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 20 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "mean": { + "data": [ + 1.5, + 2.5, + 1.9166666667, + 1.8, + 2.0, + 2.0, + 2.2, + 1.0, + 2.4444444444 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + + ], + "measures": { + "mean": { + "data": [ + 1.5833333333 + ], + "n_missing": 8, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 20 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "mean": { + "data": [ + 1.3333333333, + 0.6666666667, + 2.1666666667, + 1.75, + 1.6666666667, + 1.4, + 1.5, + 2.0, + 1.25 + ], + "n_missing": 8, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 12, + 5, + 3, + 12, + 5, + 6, + 9 + ] + } + } + ] + }, + { + "result": [ + { + "result": { + "dimensions": [ + { + "references": { + "description": "", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Country", + "alias": "country", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": null, + "missing": false, + "id": 1, + "name": "Argentina" + }, + { + "numeric_value": null, + "missing": false, + "id": 2, + "name": "Australia" + }, + { + "numeric_value": null, + "missing": false, + "id": 3, + "name": "Austria" + }, + { + "numeric_value": null, + "missing": false, + "id": 4, + "name": "Belgium" + }, + { + "numeric_value": null, + "missing": false, + "id": 5, + "name": "Brazil" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 4, + 4, + 4, + 4, + 4, + 0 + ], + "n_missing": 0, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 4, + 4, + 4, + 4, + 4, + 0 + ] + } + }, + { + "result": { + "dimensions": [ + { + "references": { + "description": "", + "format": { + "summary": { + "digits": 0 + } + }, + "notes": "", + "name": "Country", + "alias": "country", + "view": { + "show_counts": false, + "show_numeric_values": false, + "include_missing": false, + "column_width": null + } + }, + "derived": false, + "type": { + "ordinal": false, + "class": "categorical", + "categories": [ + { + "numeric_value": null, + "missing": false, + "id": 1, + "name": "Argentina" + }, + { + "numeric_value": null, + "missing": false, + "id": 2, + "name": "Australia" + }, + { + "numeric_value": null, + "missing": false, + "id": 3, + "name": "Austria" + }, + { + "numeric_value": null, + "missing": false, + "id": 4, + "name": "Belgium" + }, + { + "numeric_value": null, + "missing": false, + "id": 5, + "name": "Brazil" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + }, + { + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "name": "All pets owned", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "derived": true, + "type": { + "subtype": { + "class": "variable" + }, + "elements": [ + { + "id": 1, + "value": { + "derived": false, + "references": { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0001" + }, + "missing": false + }, + { + "id": 2, + "value": { + "derived": false, + "references": { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0002" + }, + "missing": false + }, + { + "id": 3, + "value": { + "derived": false, + "references": { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + "id": "0003" + }, + "missing": false + } + ], + "class": "enum" + } + }, + { + "derived": true, + "references": { + "uniform_basis": false, + "description": "Do you have any of these animals as pets? Please select all that apply.", + "format": { + "summary": { + "digits": 0 + } + }, + "subreferences": [ + { + "alias": "allpets_1", + "name": "Cat", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_2", + "name": "Dog", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + }, + { + "alias": "allpets_3", + "name": "Bird", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + } + } + ], + "notes": "", + "alias": "allpets", + "view": { + "show_counts": false, + "include_noneoftheabove": false, + "include_missing": false, + "column_width": null + }, + "name": "All pets owned" + }, + "type": { + "ordinal": false, + "subvariables": [ + "0001", + "0002", + "0003" + ], + "class": "categorical", + "categories": [ + { + "numeric_value": 1, + "selected": true, + "id": 1, + "missing": false, + "name": "Selected" + }, + { + "numeric_value": 0, + "missing": false, + "id": 0, + "name": "Other" + }, + { + "numeric_value": null, + "missing": true, + "id": -1, + "name": "No Data" + } + ] + } + } + ], + "measures": { + "count": { + "data": [ + 1, + 2, + 1, + 1, + 0, + 3, + 1, + 2, + 1, + 0, + 1, + 3, + 2, + 2, + 0, + 1, + 2, + 1, + 1, + 0, + 3, + 0, + 0, + 4, + 0, + 2, + 2, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 1, + 0, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ], + "n_missing": 3, + "metadata": { + "references": { + + }, + "derived": true, + "type": { + "integer": true, + "missing_rules": { + + }, + "missing_reasons": { + "No Data": -1 + }, + "class": "numeric" + } + } + } + }, + "n": 20, + "filter_stats": { + "filtered_complete": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + }, + "filtered": { + "unweighted": { + "selected": 20, + "other": 0, + "missing": 0 + }, + "weighted": { + "selected": 20, + "other": 0, + "missing": 0 + } + } + }, + "unfiltered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "filtered": { + "unweighted_n": 20, + "weighted_n": 20 + }, + "counts": [ + 1, + 2, + 1, + 1, + 0, + 3, + 1, + 2, + 1, + 0, + 1, + 3, + 2, + 2, + 0, + 1, + 2, + 1, + 1, + 0, + 3, + 0, + 0, + 4, + 0, + 2, + 2, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 0, + 1, + 3, + 2, + 0, + 2, + 1, + 0, + 3, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0 + ] + } + } + ] + } + ] +} diff --git a/tests/testthat/fixtures/buildFixtures-1-2-5.R b/tests/testthat/fixtures/buildFixtures-1-2-5.R index f719bb10..84ce442c 100644 --- a/tests/testthat/fixtures/buildFixtures-1-2-5.R +++ b/tests/testthat/fixtures/buildFixtures-1-2-5.R @@ -21,6 +21,13 @@ ct_banner <- banner( vars = list(`banner 1` = 'allpets') ) +# For codebookItemTxt +codebookItemTxt(ds$q1) +codebookItemTxt(ds$allpets) +codebookItemTxt(ds$ndogs) +codebookItemTxt(ds$wave) +codebookItemTxt(ds$q3) + topline_unweighted <- crosstabs( ds, include_numeric = TRUE,