2022年9月24日土曜日

Data Science work in MIT AppInventor with new Data Charts components

MIT App Inventor is continuously being upgraded in a wide range of ways, from new features incorporating cutting-edge AI technology to convenient features for daily application development. The members of the development team also seem to have grown even more recently. This time, I tried the newly added Data Chart function. Very convenient!

Until now, there was no built-in function for drawing graphs, so if necessary, we used extension functions developed by volunteers, or drew them offline with Excel. Now, anyone can use Data Chart as a standard feature right away. It facilitates visualization of various data. Chart types include standard line charts, bar charts, pie charts, scatter charts, and more. It also has support for many types of data sources.

You can easily draw a graph from a list as shown in Figure 1. The function to convert CSV format and JSON format data to a list is already built in, so this is easy to use. Also, we can use Spreadsheet, CloudDB, and TinyDB as data sources, so they are very convenient when large data files already exist. In addition, adding single point to a  graph is available, so it can be used to display data from various sensors in real time.
Here is one application that uses this Data Chart. This is a recording app of atmospheric pressure fluctuations. Figure 2(a) shows real-time air pressure ​​obtained in a short term from the barometer built into the smartphone.

On the other hand, Fig. 2(b) shows the atmospheric pressure fluctuation when Typhoon No. 19 passed nearby in 2019. The data acquired at intervals of about 5 minutes over 12 hours was stored in CSV file, and it is displayed. You can see that the air pressure dropped sharply at the time of closest approach, and immediately turned to rise.

As the graph shows, the atmospheric pressure of the typhoon at that time dropped by about 40hPa in a few hours, so it was a fairly strong typhoon. Even with a personal smartphone, you can feel the approach of a typhoon like this. If many people do this kind of thing in various places and aggregate those data, it seems to make some big thing.

0 件のコメント:

コメントを投稿