Convert GRIB to JSON object - json

Previously I have worked on a project that reads and displays wind direction forecast using GRIB data retrieved from the following NOAA website:
http://nomads.ncep.noaa.gov/cgi-bin/filter_gfs_1p00.pl
The GRIB data downloaded is then converted to JSON object using utility tool 'grib2json'.
However, I was asked to take in GRIB data from the following Japan website instead:
http://www.wis-jma.go.jp/d/o/RJTD/GRIB/Global_Spectral_Model/Latitude_Longitude/1.25_1.25/60.0_-20.0_60.0_200.0/925hPa/
However, I realized that the GRIB format for both sources is different. And the utility 'grib2json' does not work on GRIB data from Japan.
I need help on how to convert the Japan GRIB data to JSON so that I can still reuse my source codes to display the wind direction forecast.

Related

how to mass convert json to csv?

Greetings is there a tool to mass convert json to csv like this.
EDIT 1
I'm working on a DND application and i am using this jsons but before putting them into a db i want to mass convert them into csv and not one by one with an online tool.

Where do I write a JSON file

I have spent a few hours reading about JSON online and have read a JSON for beginners text book. However, I still can not find out how to start using JSON to store data. Is there a JSON download or interface that is used or do you store JSON files in other languages like python?
I understand JSON is a file format, but where do I write and store JSON files?
My question is different than the suggested duplicate because it is more narrow. My question specifically asks "where do I write a JSON file?", as opposed to "how do I use JSON?"
DISCLAIMER I'm brand new to coding and don't have a teacher to consult to ask questions. I am asking this question because I am genuinely trying to learn and this information is not available online, nor in the textbook that I purchased.
Thank you in advance for your help!
JSON is a file format for storing and passing data between, you can create a JSON file in any text editor, it should follow the JSON format that's it , you can validate the format of your JSON using online validators, I usually use https://jsonlint.com/, JSON is a standard which is supported by almost every programming language, you have API in every language to support it.
you can find examples of JSON data here http://json.org/example.html
just copy them and store them in a file with extension ".json", you can read them from your program by specifying the path where the file is present on the file system.

Importing a JSON data file into Tableau

I'm a parse.com novice. I had an iPhone app built that sent to and stored data with parse(core). The variables it stored were image, latitude, longitude, time,and type. It stored the information like a spreadsheet - each image was associated with a latitude, longitude, time and type. I wanted to use Tableau to take this data and create a visual representation, but I can't figure out how to import the data into Tableau. When I export the parse file as a JSON file, it seems to be in string format, and Tableau does not recognize it as a table. Is there a way I can export the parse data so tableau can easily recognize it as a data table?
In my experience this can be best handled by writing some Tableau Extract API to convert your data to Tableau TDEs. If you want to schedule such refresh, you can use "addtoFile" tabcmd to add these TDEs to the existing dashboards.
Currently Tableau does not support out of box JSON support. Here is the latest discussion in the Tableau ideas forum.
Here
Also i will recommend looking at the latest Web Data Connector. They will be very handy for lot of use cases.
Tableau does not read JSON data natively. By using Apache Drill, you can use Tableau to point at JSON data and start analyzing it.
Here is the link for complete explanation.

How to give simple edge list format for Apache Giraph

I am trying to run Stanford Network Analysis Program (SNAP) graphs on Apache Giraph using Hadoop.
The link is provided below http://snap.stanford.edu/snap/
Currently I am trying to run the facebook graph which is in the simple edge list format
source_id destination_id
..
Link is : http://snap.stanford.edu/data/egonets-Facebook.html
I am not able to determine which format does Apache Giraph accept to run the SimpleShortestPathsCompute or any other Java Program for accepting input of the simple edge list format.
I was successfully able to run SimpleShortestPathsCompute and PageRankComputation Algorithms which are in the examples folder of the Giraph package on input files with JSON Format.
[source_id, source_value, [[destination_id, edge_value], [destination_id, edge_value],..]]
For all those people who are facing problems trying to run example Java programs given in the Jar package.
In my case I write an algorithm in Java which converts the given input file in the simple edge list format to the Json Based Format.
The simple edge list format has the following form
source_id, destination_id
...
Since the graph I was working on was an undirected graph (i.e facebook snap graph), an edge written once between any two vertices (nodes) is not repeated a second time. e.g if I have a graph that has an edge between the vertices 1 and 20 will be written as
1 20
. . .
and 20 1 will be avoided.
So first convert the graph in the following format which has both the edges.
Since an undirected graph is a directed graph with directed edges in both the directions between any two vertices connected by an edge.
After that write an algorithm that converts this format into the JSON format and store the output in the output file and then run the SingleSourceShortestPathsCompute and PageRank and other sample algorithms on this graph.

How to localise JSON data for windows phone 8 app

I have JSON data which has say three levels of nesting.I need to support localization of my app.I can find resources on how to create res file and support multiple languages,But they all seem to be for a single string.How do I place my nested JSON data in res file??
There are two simple ways to solve the problem that may work for you:
Depending on the size of the JSON file, you can just store the stringified JSON data as a string resource. For small amounts of data, it's a simple solution.
For larger files, I'd suggest instead that you store a file name/path which points at the corresponding JSON file that is appropriate for the current locale. You'd just load the file based on the file name provided in the resource at run time.