[Eeglablist] Generate jpg, png, gif formats through topoplot function without the need to save it manually

Victor Gimenez victor.gimenez at ufabc.edu.br
Wed Apr 13 14:09:44 PDT 2022


Hi Andreas,



The figure that topoplot returns me is from surface type with 12 
attributes as: CDataModel, VertexNormalsMode, FaceNormalsMode... i am 
reading the print documentation but I can't able to see nothing where 
could I find to pass the img from surface type as a parameter, any tips?

I am doing the code as:

img = topoplot(EEG.data(1,1:3071,3),EEG.chanlocs,'style','map');


Thank you,

Victor

Em 2022-04-13 06:03, Andreas Widmann escreveu:
> print( '-dpng', 'somefilename.png', '-r300‘ )
> exports the current figure as png from the CLI (with 300 dpi
> resolution). Same principle for jpg, etc.
> 
> Adding a figure handle to the print command can be helpful if plotting
> and exporting multiple figures (e.g., in a loop):
> figHandle = figure;
> your_plot_command
> print(figHandle, '-dpng', 'somefilename.png', '-r300‘)
> 
> Hope this helps! Best,
> Andreas
> 
>> Am 12.04.2022 um 21:28 schrieb Victor Gimenez 
>> <victor.gimenez at ufabc.edu.br>:
>> 
>> Good Morning/Afternoon/Evening dear EEGLab community,
>> 
>> 
>> 
>> I am trying to return the data obtained from the execution of topoplot 
>> function directly to write a file in any of these image formats: .jpg, 
>> .gif, or .png (without the need to file > save_as blablabla) instead 
>> to only plot the data at the screen because I am looking for to save 
>> more image contents to generate a dataset of samples.
>> 
>> I already did: tp = topoplot(<EEG input data to be 
>> read>,EEG.chanlocs,'style','map'); but it returned me only a 1x1 
>> surface type data that I can't able to open directly without EEGLab or 
>> execute functions as imread and ind2rgb to convert the image data into 
>> an rgb array.
>> 
>> Is there any way to save directly the topological map data in any type 
>> only through code??
>> 
>> 
>> Thanks in advance,
>> 
>> Victor
>> _______________________________________________
>> Eeglablist page: http://sccn.ucsd.edu/eeglab/eeglabmail.html
>> To unsubscribe, send an empty email to 
>> eeglablist-unsubscribe at sccn.ucsd.edu
>> For digest mode, send an email with the subject "set digest mime" to 
>> eeglablist-request at sccn.ucsd.edu

-- 
Victor Borghi Gimenez


Computer Science M.Sc. Student - Center for Mathematics, Computing and 
Cognition - Federal University of ABC (UFABC) 
https://urldefense.proofpoint.com/v2/url?u=https-3A__www.ufabc.edu.br_en_&d=DwIDaQ&c=-35OiAkTchMrZOngvJPOeA&r=kB5f6DjXkuOQpM1bq5OFA9kKiQyNm1p6x6e36h3EglE&m=ZvioFDKA7UEm8300fYD8TPXbWyI8RWBSTQ7OSQCO_uUjoSU6Uu-Ka04HwHJSLNMh&s=Xu-4-tI96fcJZzDkBIRU07ogHLxQAuCF_3j3BPtbls8&e= 
System Analysis and Development Technologist - São Caetano do Sul 
College of Technology (FATEC-SCS) https://urldefense.proofpoint.com/v2/url?u=https-3A__www.fatecsaocaetano.edu.br_&d=DwIDaQ&c=-35OiAkTchMrZOngvJPOeA&r=kB5f6DjXkuOQpM1bq5OFA9kKiQyNm1p6x6e36h3EglE&m=ZvioFDKA7UEm8300fYD8TPXbWyI8RWBSTQ7OSQCO_uUjoSU6Uu-Ka04HwHJSLNMh&s=mMAv73V0l2ym3u_fQBTHTAUG069Hf3F2mO4HCKXNt60&e= 

https://urldefense.proofpoint.com/v2/url?u=http-3A__lattes.cnpq.br_4344720857265863&d=DwIDaQ&c=-35OiAkTchMrZOngvJPOeA&r=kB5f6DjXkuOQpM1bq5OFA9kKiQyNm1p6x6e36h3EglE&m=ZvioFDKA7UEm8300fYD8TPXbWyI8RWBSTQ7OSQCO_uUjoSU6Uu-Ka04HwHJSLNMh&s=yAetRUpdBT0SLa0K10xcZbT8dSFB31B6lR1wv9MLCdw&e= 
https://urldefense.proofpoint.com/v2/url?u=https-3A__www.linkedin.com_in_victor-2Dborghi-2Dgim-25C3-25A9nez-2D04466666_&d=DwIDaQ&c=-35OiAkTchMrZOngvJPOeA&r=kB5f6DjXkuOQpM1bq5OFA9kKiQyNm1p6x6e36h3EglE&m=ZvioFDKA7UEm8300fYD8TPXbWyI8RWBSTQ7OSQCO_uUjoSU6Uu-Ka04HwHJSLNMh&s=myia3NGMv8OtdXbIsVry6CCDx5HFtvx3rzY2f-WV9pc&e= 
https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_VictorGimenez&d=DwIDaQ&c=-35OiAkTchMrZOngvJPOeA&r=kB5f6DjXkuOQpM1bq5OFA9kKiQyNm1p6x6e36h3EglE&m=ZvioFDKA7UEm8300fYD8TPXbWyI8RWBSTQ7OSQCO_uUjoSU6Uu-Ka04HwHJSLNMh&s=Gvi49GCWGyyzeAQdzoofOLRQvraE7MD8LRSJIZFhISY&e= 



More information about the eeglablist mailing list