I am working on a Ladybug sheet calculating the solar radiation received at a specific location at every hour and day of the year.

So I have a list of a few thousands values of radiations, that I calculated from the sun’s positions throughout the year using “SunPositions” of “SunPath”. I can also get the dates and times corresponding thanks to “SunPositionsInfo” of “SunPath” component.

Now I want to sum, for every day, the radiations received bu the surface in order to calculate the total daily radiation.

My problem is that I don’t know how to detect and inquire change of date, and then how to sum values of each day to obtain a list of 365 daily values. The Ladybug sheet explaining my issue is attached.

I think your primary issue is you may want to revise the components you are using. I recommend building up a logic using the radiation analysis component. From it you can get the sum radiation for a specified range.

If it was me, I would set this up. Then automate sliders connected to a date range which step through each day. And have the results recorded in something like Excel through export and reporting add-on components That way I could track sum changes for each day in a relative efficient manner.

Try this workflow where I used native components of GH. If I have understood correctly, you mean daily solar direct radiation of your specific location without using EPW file.

If you want to do solar radiation analysis of geometries you should use LB_RadiationAnalysis as Dustin told you.

Thank you for your answer ! I’m just starting with Ladybug and I had not seen we could do some radiation analysis ! So I made a sheet calculating it from the formulas I had. I guess I have some other tutorials to watch Thanks for letting me know about it.

Actually my problem was not really about radiation calculation but more some original Grasshopper treatment but anyways, I managed to solve the problem already !

Thank you for your answer ! Your method works perfectly for what I wanted to do and is very optimal. You’re right it was just an issue about native component, but since it used Ladybug components, I thought it was best to ask about it on this forum. Anyways, problem solved ! Thanks a lot