Wolfram Cloud (Mathematica) Demo: Importing JSON Data and using the Values and ToExpression methods
In this video we look at import data from a JSON file. It created a list of lists of key-value pairs. We selected out some presumably numeric data (the distance and velocity of planets) but could not plot it. Then we used the Values method which extracted just the values from the key-value pairs. We could still not plot because the data was not recognized as numerical since the numbers were in quotes in the JSON file. We finally added the ToExpression method into the mix, and we could plot the data with ListPlot. We then used Reverse to swap the x and y values in the ListPlot. Finally we used FindFit to fit the data to a power-law form.
Видео Wolfram Cloud (Mathematica) Demo: Importing JSON Data and using the Values and ToExpression methods канала Thomas Blum
Видео Wolfram Cloud (Mathematica) Demo: Importing JSON Data and using the Values and ToExpression methods канала Thomas Blum
Комментарии отсутствуют
Информация о видео
19 января 2023 г. 4:18:49
00:14:27
Другие видео канала