Computer Science, asked by nadirnishanth5000, 1 month ago

write code to creqte a Dataframe and subtract mean of a row from each elements of the row in a Dataframe ​

Answers

Answered by Anonymous
0

Answer:

I have a dataframe with rows indexed by chemical element type and columns representing different samples. The values are floats representing the degree of presence of the row element in each sample.

I want to compute the mean of each row and subtract it from each value in that specific row to normalize the data, and make a new dataframe of that dataset.

I tried using mean(1), which give me a Series object with the mean for each chemical element, which is good, but then I tried using subtract, which didn't work.

Similar questions