Re: Save values of a matrix

Skip to first unread message

Marcel Luethi

Dec 23, 2020, 5:01:21 AM12/23/20
to Ilaria A., scalismo
Hi Ilaria

Yes, you can save a matrix as a csv file as follows:

val matrix = DenseMatrix.rand(10, 10)
val csvWriter = breeze.linalg.csvwrite(new"afile.csv"), matrix)

You could also just restrict the output to a part of the matrix (in this case the first 10 rows and columns) as follows:
matrix(0 until 10, 0 until 10)

Best regards,


On Tue, Dec 22, 2020 at 6:49 PM Ilaria A. <> wrote:

Hello everybody,
I have a question: is there a way to save or export the values of a matrix (like basisMatrix) that I computed in ScalismoLab?
Because when I display a matrix in Scalismo it is  truncated but I need to see all values of my matrix.

Thanks in advance,

You received this message because you are subscribed to the Google Groups "scalismo" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
To view this discussion on the web visit
Reply all
Reply to author
0 new messages