Skip to content

Instantly share code, notes, and snippets.

Скачиваем в локальную репу yum последние версии постгреса

sudo yum localinstall https://download.postgresql.org/pub/repos/yum/reporpms/EL-7-x86_64/pgdg-redhat-repo-latest.noarch.rpm

Устанавливаем 10ый постгрес

sudo yum install -y postgresql10-server.x86_64 postgresql10-contrib.x86_64 postgresql10-libs.x86_64
books.groupby('authors').mean().reset_index()
books.groupby('authors',as_index=False).mean()
grouped_df = books.groupby('authors').mean()
grouped_df.loc['A.M. Homes']
books['average_rating'].mean()
books[books['authors'] == 'J.K. Rowling-Mary GrandPré']['average_rating'].mean()
sum(values)/len(values)
values = books[books['authors'] == 'J.K. Rowling-Mary GrandPré']['average_rating'].values
values
books[books['authors'] == 'J.K. Rowling-Mary GrandPré']
books.groupby('authors')[['ratings_count','average_rating']].describe()