Hi, i wanted do load the swissmap JSON file from GADM into Scilab 2023.1. Level 0 works with 34kb. But Level 1 with unzipped 134kb crashes Scilab on windows 11. Could anyone confirm this, before making a Bug.
You are right, there is a crash (tested on Scilab 2024.0.0 macOS version). Can you take the time to create a Gitlab account and create an issue at Issues · scilab / scilab · GitLab? Please include your code above as modified (I have changed the path of the file so that anybody can copy/paste it).
I made my plots with extracting the Datas out of the structs.
Now i have another question in the struct there is this structure at the end:
coordinates: --1 (sub --1 ,–2) --2, --3 and --4.
So how do i parse this elegantly in one for loop, to obtain all values in a row, i tried many ways, (try-catch 7 index i,j) etc, but none of them was satisfying. Any Ideas or suggestions?
For very special cases, you can serialize structs, typically when the fields are on the same level, of array type, and can be concatenated along a given dimension, e.g.:
clear a
a.x=1:3
a.y=sin(1:3)
cat(1,a(fieldnames(a)))
which yields
--> a.x=1:3
a = [struct] with fields:
x = [1,2,3]
--> a.y=sin(1:3)
a = [struct] with fields:
x = [1,2,3]
y = [0.841471,0.9092974,0.14112]
--> cat(1,a(fieldnames(a)))
ans = [2x3 double]
1. 2. 3.
0.841471 0.9092974 0.14112
Na, not really what i want.
I’ve tried something else like if error “Invalid index” then continue else take the datas, but it does not work. i somehow need to handle this “Invalid index”.
M.f.G. Pascal
PS: With CURL will there be also a toolbox for MQTT an WS?