Df = df.apply(lambda x: np.square(x) if x.name in [ 'a', 'e', 'g'] else x, axis=1)
Df = df.apply(lambda x: np.square(x) if x.name in [ 'a', 'e', 'g'] else x, axis=1)
0
Source: machinelearningplus.com
- 0 vote305 views1 answer
- 7 votes341 views2 answers
- 0 vote401 views1 answer
- -1 vote342 views1 answer
- 15 votes350 views2 answers
- 6 votes324 views2 answers
- 0 vote340 views2 answers
- 8 votes339 views3 answers
- 27 votes328 views6 answers
- 0 vote334 views1 answer