In this Gist, we look at how you can convert a Gen3 Data Dictionary from YAML to JSON.
First, we need a copy of the dictionary that's in YAML format so that we can convert it to JSON.o
git clone https://github.com/uc-cdis/compose-services.git
In this Gist, we look at how you can convert a Gen3 Data Dictionary from YAML to JSON.
First, we need a copy of the dictionary that's in YAML format so that we can convert it to JSON.o
git clone https://github.com/uc-cdis/compose-services.git
The Gen3 developers use Travis CI to test their data dictionaries. Why not test locally? The data dictionary tests use some tools (poetry and nose) that may be difficult to install.
In this Gist, we will provide instructions on how you can use Travis-CI to test the dictionary that comes with Compose Services.
First, we need a copy of the dictionary so that we can perform a test on it.
According to a conversation with a Gen3 developer, the working tool is on the charlie_fix
branch of the gen3_dictionary_tools
repo.
In this code chunk, we clone the branch and set up the environment.
git clone --single-branch --branch charlie_fix https://github.com/uc-cdis/gen3_dictionary_tools.git
cd gen3_dictionary_tools/Dictionarytool/
According to a conversation with a Gen3 developer, the working tool is on the charlie_fix
branch of the gen3_dictionary_tools
repo.
In this code chunk, we clone the branch and set up the environment.
git clone --single-branch --branch charlie_fix https://github.com/uc-cdis/gen3_dictionary_tools.git
cd gen3_dictionary_tools/Dictionarytool/
library(magrittr) | |
library(ggplot2) | |
# Trying to reproduce Figure 9.3 from the | |
# Second Edition of "Statistical Rethinking" | |
# by Richard McElreath | |
########################################################## | |
# Main Steps: | |
# 1. Try to identify the posterior used by McElreath |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Document</title> | |
<script src="https://d3js.org/d3.v5.min.js"></script> | |
</head> |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Document</title> | |
<script src="https://d3js.org/d3.v5.min.js"></script> | |
</head> |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Document</title> | |
<script src="https://d3js.org/d3.v5.min.js"></script> | |
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/1.0.0/css/materialize.min.css"> |
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Document</title> | |
<script src="https://d3js.org/d3.v5.min.js"></script> | |
</head> |
<!DOCTYPE html> | |
<head> | |
<script src="https://d3js.org/d3.v5.min.js"></script> | |
</head> | |
<body> | |
<div id = "chart"></div> | |
<button type="button" style = "position: absolute; left: 550px">Click to Restart</button> | |
<script src="index.js"></script> |