-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Крайзель Андрей. Pandas and EDA #1
base: main
Are you sure you want to change the base?
Conversation
} | ||
], | ||
"source": [ | ||
"mask = np.linspace(2, 12, 25).reshape(5,5)\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Должно было быть mask = np.random.uniform(2, 12, (5, 5))
"print(True if p_inf in a else False)\n", | ||
"for el in range(len(a)):\n", | ||
" if a[el] == p_inf:\n", | ||
" a[el] = 0\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Вместо цикла лучше применять
a = np.where(np.isnan(a) | np.isinf(a), 0, a)
"b = np.isnan(np.sum(a))\n", | ||
"print(b)\n", | ||
"p_inf = float('inf')\n", | ||
"print(True if p_inf in a else False)\n", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Лучше использовать функцию Numpy np.isinf(a)
5 балла |
В 4-5 задании перепутали для среднеквадратических значений, взяли из dataframe_1, а надо было dataframe_2. |
В 6 задании |
5 баллов |
В задании №3 можно сделать так: |
5 баллов |
No description provided.