12-07-2021 09:17 PM
Thank you for the responses. I tried to implement what you have but I cannot figure it out. Also, I don't understand how the grading is being done and the conditions which were set. If possible would would be able to share the VI. Thank you.
12-07-2021 10:13 PM
Thank you for the responses. I tried to implement what you have but I cannot figure it out..
Show us how far you got.
12-07-2021 10:53 PM
Here is the altered VI. I don't know know how to add different kinds of controls to the bundle function which is what I was stuck on. Like country, # and grade. Also if you could explain the grading process that would be very helpful. Also I tried my best to implement what you have but I'm not sure if its wired correctly. It took me a long time to figure it out what I have now.
12-08-2021 01:27 AM
12-08-2021 10:42 AM
To make it easier on yourself (and others), use the Save to Previous (under the File Menu) feature. Version 18 should be sufficient unless others chime in. Name it differently and attach.
12-08-2021 04:53 PM
Thank you for your help. I really appreciate it. Sorry I uploaded a file you could not open, this was my first time using these forums I did not realize. I got the grading to work all thanks to your help and the explanation you provided. I ran into a problem because 224/50 is greater than 2 but I was able to tweak it to work properly based on just adding a C grade to anything greater than 2.
Also, since you're very knowledgeable on lab view and I already have your attention. I've been struggling on how to rank the countries based upon the least emissions in your code it would be the #/persons value. In the sense of giving the least emissions 1, second least 2, etc. Also, which version of lab view would you like me to save and upload for you in the future? version 18? or screenshots?
12-08-2021 05:01 PM - edited 12-08-2021 05:11 PM
I ran into a problem because 224/50 is greater than 2 but I was able to tweak it to work properly based on just adding a C grade to anything greater than 2.
That's why I coerce that value to between 0 and 2! (most often any little piece of my code has a good reason to be there!)
I've been struggling on how to rank the countries based upon the least emissions in your code it would be the #/persons value. In the sense of giving the least emissions 1, second least 2, etc.
What do you mean by "rank"? Sort them by that value? Add another element to the cluster that indicates rank? Seems easy. What have you tried?
Also, since you're very knowledgeable on lab view and I already have your attention.
You can make a big step in your LabVIEW skills by just learning how to spell it! No, it is not "lab view"! Lettercase is important, otherwise it could just be a picture of the view of a lab). Know the difference!
(I can do version 2020 or anything lower)
12-08-2021 05:15 PM
Thank you for the response. To clarify "Add another element to the cluster that indicates rank" is exactly what I meant. I haven't been able to physically write any code because I am brainstorming on how to approach this and haven't came out with a way to do it. Some of the ways I thought about doing it was to use the same grading methodology, however, that would result in multiple countries being ranked the same. Another way I thought about it was to do a series of booleans to compare the individual values, however, this seems very inefficient and probably not possible. If you could steer me in a general direction I can see if I get it figured out.
12-08-2021 05:45 PM - edited 12-09-2021 12:51 PM
All you really need to know is that in LabVIEW, sorting arrays of clusters will sort hierarchically by cluster order.
So here's how that could look like. Make sure you fully understand it:
12-09-2021 02:53 PM - edited 12-09-2021 02:56 PM
Hello, altenbach. I am not familiar with the function you used in the 2nd for loop. I recognize that the index array notation, but I am at a loss as to how to get my block diagram to look like yours. I've gone through the functions palette and was not able to find it. I would appreciate any guidance you could give me!