Skip to content

summarize() can't use np.sqrt  #399

@HuangHam

Description

@HuangHam

Hi! So glad to find a tidyverse equivalent in python. I encountered the following issue:

data = pd.concat([df_human, df_sim]) >>
group_by(_.subj, _.trial, .split, .agent,.inequality) >>
summarize(reward = np.sqrt(np.mean(
.reward)))

Note I wanted the square root of the mean of the variable named reward. but this gives me an error: invalid array_struct . This error doesn't show up for other np functions such as np.size, np.mean, np.std. So I'm really confused...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions