Calculate meteorological variables (precipitation etc.) from Clusters

Topics about the trajectory clustering program for HYSPLIT.
Post Reply
Carlo
Posts: 8
Joined: June 8th, 2021, 10:41 am
Registered HYSPLIT User: No

Calculate meteorological variables (precipitation etc.) from Clusters

Post by Carlo »

Hello everyone,

I am new to Hysplit and would like to figure out a way to get meteorological variables like precipitation etc. from clusters. To solve the problem I have so far followed an approach where I first enabled the output of certain meteorological variables via Advanced/Configuration Setup/ Trajectory ...(6). Then I calculated a time series of trajectories using Trajectory/Special Runs/Daily Runs and clustered them using Trajectory/Special Runs/Clustering. All working steps worked, but unfortunately, I can't find a file where something like clustered meteorological variables can be found. Is this possible at all? Or how can I get such data ?

Best regards,
Carlo
alicec
Posts: 328
Joined: February 8th, 2016, 12:56 pm
Registered HYSPLIT User: Yes

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by alicec »

The clustering algorithm will tell you what cluster each trajectory was assigned to.
You can then then get the meteorological variables from the trajectory output files for each cluster and
process it how you like.
Carlo
Posts: 8
Joined: June 8th, 2021, 10:41 am
Registered HYSPLIT User: No

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by Carlo »

Thank you for your reply. So i have to use the list were all trajectories are assigned to a certain cluster and
use theiere singele files to combine them by myself ? What do you think is the best function to combine the meterologylcal varaibels. Should i for example list all the precipitation data from a cluster and then caclulate the mean value ?

Best wishes,
Carlo
hyun.kim
Posts: 18
Joined: June 11th, 2020, 8:29 pm
Registered HYSPLIT User: Yes

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by hyun.kim »

Carlo,
After cluster analysis, you can find "TRAJ.INP.C*_3" (if ncluster=3) file that includes the list of traj files for specific cluster. You can use its time stamps to separate each cluster case. If you have included specific met. variables in tdump files, "C*mean.tdump" will automatically merges tdump files for each cluster.
Carlo
Posts: 8
Joined: June 8th, 2021, 10:41 am
Registered HYSPLIT User: No

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by Carlo »

Thanks for your help, but I'm not sure if I've made a mistake or if we're talking past each other.
I have calculated trajectories including meteorological variables via special runs/daily trajectories
and placed them in the entpoint folder for the cluster calculations (see photo).
Input Files.png
Then I opened the cluster window, made the settings (Hours to cluster: 72..etc.) and started the calculation
via Run Cluster Programme/ Run cluster analysis. Then I set 4 clusters in Step 3: Get Results and pressed the Run button.
As a result, a number of files were created and calculated, including a CLUSLIST_4 that shows
which individual trajectory was assigned to which cluster.
Results after Step 3 Run.png
As a last step I created the plots via Display Means + Diyplay Cluster and received some more files.
I could not find the meteorological variables in any of the files.
After Display_looking in files.png
Therefore I think it is not possible to recive a file were the meterological variables are calculated for a cluster or have I done something wrong?
I would now take the list in which the individual trajectories were assigned to the clusters, read all the individual files into Excel and
then calculate the average values of the meteorological variables for each cluster. I think this is relatively time-consuming and I don't know if
the average reflects the "correct value". Therefore, I would be happy if you could suggest an alternative way?
If not, is the average the right way to calculate the meteorological varibale?

Best wishes,
Carlo
hyun.kim
Posts: 18
Joined: June 11th, 2020, 8:29 pm
Registered HYSPLIT User: Yes

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by hyun.kim »

Unfortunately, my answer was incorrect. trajmean does not process additional variables. At this moment, you better conduct averaging separately, using other programing language. Using Exel seems to be too troublesome. Sorry for the confusion.
Carlo
Posts: 8
Joined: June 8th, 2021, 10:41 am
Registered HYSPLIT User: No

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by Carlo »

Ah okay, thanks for the help anyway. Can anyone recommend a programme ? I'm not that familiar with programming.

Best wishes,
Carlo
hyun.kim
Posts: 18
Joined: June 11th, 2020, 8:29 pm
Registered HYSPLIT User: Yes

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by hyun.kim »

Personally, I'm using IDL (Interactive Data Language), but Python might be the most popular solution. Matlab or R will work too.
Bezunga
Posts: 1
Joined: May 6th, 2021, 10:27 am
Registered HYSPLIT User: No

Re: Calculate meteorological variables (precipitation etc.) from Clusters

Post by Bezunga »

Hmmm, thank you for the tips, I didn't know that Matlab can work in this case. Will give it a try too later on
Post Reply

Return to “Cluster Analysis”