Read gen~ data object contents inside codebox.
I cant crack this one. There isnt much in the documentation. ChatGPT cant figure it out. Its been posted on elswhere here, but i couldnt follow it. Basically, can i set contents for a data object and call them inside a code box. I dont really know the syntax to call a data object, as seen below. I dotn really have a patch to upload.

It seems this got posted a while ago so not sure if you find your answer but a few things: you don’t need to define float, int etc. in genexpr. You should be able to just do Data myData; at the beginning of your code. To access the information there or to write to it I believe it’s just like a buffer and you just use peek or poke.
If you haven’t read them yet, Gregory Taylor’s Gen~ for beginners is phenomenally helpful for getting started. The first few do not use codebox but are still essential to understanding the mechanics of Gen~. A few tutorials in he approaches the code box and genexpr.
I kinda have the same question...
And yes, the GEN~ tuts are a great start for Max MSP users who want to get into Gen, but not that great if you want to get further.
The Gen~ book is like three levels to advanced , and there is little public knowledge in the middle.
The best tuts i found so far are the hackspace videos, especially by Phelan Kane.
But back to the question...
How do we reference the data in a "data mydata" object defined in another part of the Gen patch in a codebox properly ?
Yes, i would like to build a sampleloppergranulator and use it in a Daisy :)