How does this works? verts = [[float(i) for i in r[:3]] for r in rows] I looked over here and found a csv reading script that creates curves, wich is exactly what I need, it´s cool, but I need to modify it because I need to read a differently formated csv, in fact I need to create different lists with different values, my CSV looks like this:

uniquename, x,      y,      z,      diameter,   name
401_JJ,     2800,   15500,  21400,  406,        401_JJ
a,          2800,   15500,  24150,  406,        401_JJ

The thing is that I need to extract a names list, a unique names list, a diameter list and a coordinates list.

I know that with this code I extract the first 3 rows and convert them to a vector collection, but I don´t know how to modify this and extract specific positions, for example, 2,3,4 as vectors, 1 as string, 5 as float and 6 as string.

Hope someone can help me out here.

Thanks!
Use the excellent csv module built into Python for that. The Python documentation has plenty of examples on how to read and write CSV files.

Once you have a row, you can convert individual bits to other objects, like so:

vec = mathutils.Vector([float(coord) for coord in row[1:4]])


The explicit conversion to float is necessary as CSV is untyped, so every field is returned as string.

The [f(x) for x in collection] construct is called a list comprehension, and is also explained in the Python documentation.