mito icon indicating copy to clipboard operation
mito copied to clipboard

batch update entire column

Open zhugw opened this issue 2 years ago • 4 comments

After filtering , want to batch update one entire column, e.g.

df.loc[df["C"]!="foo3", "C"] = "foo"

now mito seems does not support this update operate

zhugw avatar Aug 03 '22 02:08 zhugw

@zhugw thanks for posting this. Can you help me understanding a little bit better what you want to do here?

It's pretty much: for every row in "C" that does not equal "foo3", update it it to "foo", correct?

If so, is this useful because you're effectively trying to do a find and replace within the column?

naterush avatar Aug 04 '22 15:08 naterush

Yes, after filtering out the data I want , then want to batch update the entire column, e.g. there are 100 rows, after filtering column 1 (e.g. c1 = 'foo'), only has 10 rows, then batch update column 2 (c2 = 'bar'), How to implement in Mito?

zhugw avatar Aug 05 '22 01:08 zhugw

Currently, this is not possible (although something like this is on the update). To clarify, do you then filter to a different value like different foo and then update those as well? E.g. are you repeating this process multiple times for the same column?

naterush avatar Aug 05 '22 16:08 naterush

Very possible. This is routing data correction work. Once some problem is found, it would be modified in batches in excel

zhugw avatar Aug 06 '22 07:08 zhugw