Telegram Group & Telegram Channel
🎲 Задача с подвохом: Монетки и ошибка интуиции

Условие:

У вас есть две монеты:

• Монета A: честная, вероятность выпадения орла = 50%
• Монета B: нечестная, у неё две стороны с орлами (орёл всегда выпадает)

Вы случайным образом выбираете одну монету (с вероятностью 50% каждая) и подбрасываете её один раз. Выпадает орёл.

Вопрос:
Какова вероятность того, что вы выбрали нечестную монету (Монета B)?

🔍 Разбор:

Нам нужна вероятность:
**P(B | O)** — вероятность того, что выбрана Монета B при условии, что выпал орёл.

📈 **Быстрая формула (Байес):**

P(B | O) = (P(O | 😎 * P(B)) / (P(O | A) * P(A) + P(O | 😎 * P(B))

Подставляем:
= (1 * 0.5) / (0.5 * 0.5 + 1 * 0.5)
= 0.5 / 0.75 ≈ 0.6667

Вероятность ≈ 66,7%

💻 **Проверим симуляцией (Python):**

```python
import random

def simulate(n_trials=100_000):
count_B_given_O = 0
count_O = 0

for _ in range(n_trials):
coin = random.choice(['A', 'B']) # выбираем монету
if coin == 'A':
result = random.choice(['H', 'T']) # честная монета
else:
result = 'H' # нечестная монета (всегда орёл)

if result == 'H':
count_O += 1
if coin == 'B':
count_B_given_O += 1

prob = count_B_given_O / count_O
print(f"Симуляция: вероятность P(B | O) ≈ {prob:.4f}")

simulate()
```

Примерный вывод:

```
Симуляция: вероятность P(B | O) ≈ 0.6665
```

💥 **Подвох:**

Многие интуитивно думают, что вероятность остаётся 50%, но факт выпадения орла изменяет наше знание о ситуации — это типичная ошибка игнорирования условной вероятности.

🧠 **Что важно для Data Science:**

• Принцип обновления вероятностей лежит в основе Байесовских моделей
• Ошибки интуиции часто приводят к неправильным выводам при работе с вероятностями
• Симуляция помогает проверять теорию и укреплять понимание статистики


@machinelearning_interview



group-telegram.com/machinelearning_interview/1788
Create:
Last Update:

🎲 Задача с подвохом: Монетки и ошибка интуиции

Условие:

У вас есть две монеты:

• Монета A: честная, вероятность выпадения орла = 50%
• Монета B: нечестная, у неё две стороны с орлами (орёл всегда выпадает)

Вы случайным образом выбираете одну монету (с вероятностью 50% каждая) и подбрасываете её один раз. Выпадает орёл.

Вопрос:
Какова вероятность того, что вы выбрали нечестную монету (Монета B)?

🔍 Разбор:

Нам нужна вероятность:
**P(B | O)** — вероятность того, что выбрана Монета B при условии, что выпал орёл.

📈 **Быстрая формула (Байес):**

P(B | O) = (P(O | 😎 * P(B)) / (P(O | A) * P(A) + P(O | 😎 * P(B))

Подставляем:
= (1 * 0.5) / (0.5 * 0.5 + 1 * 0.5)
= 0.5 / 0.75 ≈ 0.6667

Вероятность ≈ 66,7%

💻 **Проверим симуляцией (Python):**

```python
import random

def simulate(n_trials=100_000):
count_B_given_O = 0
count_O = 0

for _ in range(n_trials):
coin = random.choice(['A', 'B']) # выбираем монету
if coin == 'A':
result = random.choice(['H', 'T']) # честная монета
else:
result = 'H' # нечестная монета (всегда орёл)

if result == 'H':
count_O += 1
if coin == 'B':
count_B_given_O += 1

prob = count_B_given_O / count_O
print(f"Симуляция: вероятность P(B | O) ≈ {prob:.4f}")

simulate()
```

Примерный вывод:

```
Симуляция: вероятность P(B | O) ≈ 0.6665
```

💥 **Подвох:**

Многие интуитивно думают, что вероятность остаётся 50%, но факт выпадения орла изменяет наше знание о ситуации — это типичная ошибка игнорирования условной вероятности.

🧠 **Что важно для Data Science:**

• Принцип обновления вероятностей лежит в основе Байесовских моделей
• Ошибки интуиции часто приводят к неправильным выводам при работе с вероятностями
• Симуляция помогает проверять теорию и укреплять понимание статистики


@machinelearning_interview

BY Machine learning Interview


Warning: Undefined variable $i in /var/www/group-telegram/post.php on line 260

Share with your friend now:
group-telegram.com/machinelearning_interview/1788

View MORE
Open in Telegram


Telegram | DID YOU KNOW?

Date: |

"Russians are really disconnected from the reality of what happening to their country," Andrey said. "So Telegram has become essential for understanding what's going on to the Russian-speaking world." "We're seeing really dramatic moves, and it's all really tied to Ukraine right now, and in a secondary way, in terms of interest rates," Octavio Marenzi, CEO of Opimas, told Yahoo Finance Live on Thursday. "This war in Ukraine is going to give the Fed the ammunition, the cover that it needs, to not raise interest rates too quickly. And I think Jay Powell is a very tepid sort of inflation fighter and he's not going to do as much as he needs to do to get that under control. And this seems like an excuse to kick the can further down the road still and not do too much too soon." That hurt tech stocks. For the past few weeks, the 10-year yield has traded between 1.72% and 2%, as traders moved into the bond for safety when Russia headlines were ugly—and out of it when headlines improved. Now, the yield is touching its pandemic-era high. If the yield breaks above that level, that could signal that it’s on a sustainable path higher. Higher long-dated bond yields make future profits less valuable—and many tech companies are valued on the basis of profits forecast for many years in the future. The S&P 500 fell 1.3% to 4,204.36, and the Dow Jones Industrial Average was down 0.7% to 32,943.33. The Dow posted a fifth straight weekly loss — its longest losing streak since 2019. The Nasdaq Composite tumbled 2.2% to 12,843.81. Though all three indexes opened in the green, stocks took a turn after a new report showed U.S. consumer sentiment deteriorated more than expected in early March as consumers' inflation expectations soared to the highest since 1981. Groups are also not fully encrypted, end-to-end. This includes private groups. Private groups cannot be seen by other Telegram users, but Telegram itself can see the groups and all of the communications that you have in them. All of the same risks and warnings about channels can be applied to groups.
from sg


Telegram Machine learning Interview
FROM American