# Breaking up a list of lists

I have a list of values stored in SortedLat, where SortedLat is a list of 74 sublists, and each sublist has its first element be a string. As you can see I am trying to create the first column for a table with these strings.

TableOfValues1 = Prepend[q, {"B1", "B2"}]
TableOfValues2 =
Prepend, {TableOfValues1, {"",
Partition[Table[SortedLat[[m]][[1]], {m, 1, 74}], 1]}}]


B1,B2 are just lists of 74 numbers.

I realize the problem with the code is probably that

Partition[Table[SortedLat[[m]][[1]],{m,1,74}],1]}}]


gives me a list of 74 strings instead of 74 separate strings. Therefore it gives the error that the dimensions don't match. Is there a way to break up the list of 74 strings into 74 separate strings to make the table/grid work?

Thanks.

• Is Prepend[SortedLat, {"", "B1", "B2"}] what TableOfValues2 should be? What is q? May 19, 2019 at 5:28
• sorry for the confusion, The table is originally 74x2 without labels. Table of values 1 was actually what you wrote, since B1, B2 go on the top row of the table. Table of Values 2 is adding a column on the leftmost side of the table. q is just a list of 74 sublists, each sublist containing a pair of numbers. May 19, 2019 at 5:43
• Please provide also an example dataset. May 19, 2019 at 5:46

TableOfValues2 = Join[Prepend[SortedLat[[All, {1}]], {""}], TableOfValues1, 2]