Forums > MaxMSP

print/export jit.cellblock data?


MIB
January 9, 2009 | 3:33 am

I would like the user to be able to print out the data that was collected in the jit.cellblock or alternatively export it to a spreadsheet and print it from excel or some other program.

Is this possible? I found the detox, intox, toxine objects but can’t quite work out how they should be used.

(Also, I have no working knowledge of excel, spreadsheets…)

Any pointers are greatly appreciated.


January 9, 2009 | 5:43 am

Hi javascript is a good solution. I already have it working – was looking for an excuse to learn javascript file I/O and feeling generous tonight.

Put all the included files on your Max path and check out the help file. It converts a cellblock to a CSV file (http://en.wikipedia.org/wiki/Comma-separated_values), which is a simple text format supported by spreadsheets. Tested with Excel and Open Office.

Hopefully you have Max 5. The javascript will work in 4 but the patch needs to be converted.


January 9, 2009 | 5:52 am

Dude, this is fantastic!

[ddg]
Darwin Grosse

On Jan 8, 2009, at 10:43 PM, Adam Murray wrote:

> Hi javascript is a good solution. I already have it working – was
> looking for an excuse to learn javascript file I/O and feeling
> generous tonight.
>
> Put all the included files on your Max path and check out the help
> file. It converts a cellblock to a CSV file (http://en.wikipedia.org/wiki/Comma-separated_values
> ), which is a simple text format supported by spreadsheets. Tested
> with Excel and Open Office.
>
> Hopefully you have Max 5. The javascript will work in 4 but the
> patch needs to be converted.
> –
> Adam Murray
> compusition.com



MIB
January 9, 2009 | 5:56 am

This is soooooo extremely cool!!!!!!!! Thank you so much!!!!!!!!


January 9, 2009 | 7:11 am

:) You’re welcome.


January 9, 2009 | 3:54 pm

Great, a very much needed function.
Thanks for sharing.
J-F.

> It converts a cellblock to a CSV file
> –
> Adam Murray
> compusition.com


October 4, 2009 | 5:54 am

Hi,

I was thrilled to find this thread when I searched the forum for a way to export CSV files. I just spent some time with the patch, though, and it’s only half working for me. When I try to write a file (by sending the name of the intended written-to filename to the right inlet), it successfully writes the first ten rows. Nothing else is transferred.

When I try to read a file, after selecting a CSV file from the resulting dialog, nothing happens, and the [bang] that I used to trigger the reading stays yellow, as if hanged. However, the rest of Max continues to work fine.

I opened up the JS file to see if maybe there was a maximum number of rows that I could increase; I don’t think there is.

Has this file been updated somewhere else that I’m unaware of? Or is there some alternate way to export to CSV? I’m running Max 5.0.8 on Mac OS X 10.5.8.

Thanks,
Jeff


October 4, 2009 | 9:09 pm
dopethatwantscash@yahoo.com wrote on Sat, 03 October 2009 22:54
Hi,
When I try to write a file (by sending the name of the intended written-to filename to the right inlet), it successfully writes the first ten rows. Nothing else is transferred.

Hmmm… I haven’t used this in a while but I just tried and it’s working for me on Max 5.0.8 & OS X 10.5.8.

Is your matrix very big? Maybe there’s some sort of memory/performance issue when trying to use this on a lot of data. But I tried on a 20 column x 500 row matrix with a single number in each cell, and that worked.

Quote:
When I try to read a file, after selecting a CSV file from the resulting dialog, nothing happens, and the [bang] that I used to trigger the reading stays yellow, as if hanged. However, the rest of Max continues to work fine.

There is no ‘read’ feature. This object only converts jit.cellblocks to csv files (hence the name cellblock2csv). When you bang and select a file, you’re choosing the file to write to, and it will overwrite whatever is in that file, so be careful!

Anyway, I also see this stuck yellow button behvaior. I think it’s a weird bug in Max that happens when you connect a button to the opendialog object. It seems harmless, but it’s easily fixed by putting a deferlow in front of the opendialog object. I attached an updated cellblock2csv.maxpat


November 6, 2009 | 8:07 pm

Hi there,

I love when I come here trying to solve a problem and I find a thread like this!

I’m not exactly clear which inlets and outlets to connect to what in your patch – would someone be able to help me out with connecting this to a cellblock so that it works?

Cheers,
joel


November 6, 2009 | 9:19 pm
joel@squarewave.ca wrote on Fri, 06 November 2009 12:07
Hi there,
I’m not exactly clear which inlets and outlets to connect to what in your patch – would someone be able to help me out with connecting this to a cellblock so that it works?

In the zip file I attached near the top of this thread, there’s a .maxhelp file that shows you how to hook it up.


November 6, 2009 | 9:25 pm

Oh dear lord… shouldn’t my brain be getting smarter with each moment spent working on these things…? Of course… the help file.

Thank you for this.

Greatly.

Cheers,
Joel


January 12, 2010 | 3:30 am

I got a request for a link to the cellblock2csv object, since the attachment on the forum seems to be lost. If anyone is looking for it, you can get it here: http://github.com/adamjmurray/max_csv_tools/zipball/0.5

That link is for the current version as of Jan 11, 2010. Check the main project page for the most recent version: http://github.com/adamjmurray/max_csv_tools

PS – Sorry about the weirdly named zip file, that’s how github works. It’s super easy for me to share patches this way so get used to it ;)


March 14, 2013 | 8:47 am

I’m looking for a way to do exactly this.
with max 6.0.8, os 10.8.2, everything is written in one single colunm.
I’m quite sure there is an easy solution but my knowledge of js and csv format is very limited.

Is there someone who can help ?

Thanks,

Yoann


Viewing 13 posts - 1 through 13 (of 13 total)