#๐Ÿ”’ Estimator

43 messages ยท Page 1 of 1 (latest)

silk sun
#

Hello how to code this please

thanks

cloud terraceBOT
#

@silk sun

Python help channel opened

Remember to:

  • Ask your Python question, not if you can ask or if there's an expert who can help.
  • Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
  • Explain what you expect to happen and what actually happens.

:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.

tawny ibex
#

These are all functions that are available in standard Python.

silk sun
#

i'm supposed to code them

tawny ibex
#

You'll need some data as well.

#

How is that arranged / presented?

#

There is also some poor English in the last paragraph. It is unclear what you are expected to do there.

#

Perhaps sight of the data would clarify that.

#

But perhaps some more explanation from you would help.

silk sun
#

in 10 minutes pls

#

i'm still in class sorry

tawny ibex
#

If you are in class, then ask your teacher.

#

Or even your classmates.

silk sun
#

ok nevermind

tawny ibex
#

Also, since this is homework, then you had better do it yourself. When you have a problem, ask about that problem.

silk sun
#

it's not homework

tawny ibex
#

What have you done so far?

silk sun
#

it's not marked

#

import numpy as np
import matplotlib.pyplot as plt

X=[]
n=200
pas=10
moyennes1=[]
variances1=[]
moyennes2=[]
variances2=[]
moyennes3=[]
for j in range(20):
for i in range(10000):
X=np.random.normal(0,1,20+10*j)
T1=np.sum(X)/n
T2=np.median(X)
T3=(np.max(X)+np.min(X))/2
moyenne1=np.mean(T1)
moyenne2=np.mean(T2)
moyenne3=np.mean(T3)

moyennes1.append(moyenne1)
moyennes2.append(moyenne2)
moyennes3.append(moyenne3)
# variances1.append(variance1)

plt.plot(moyennes1)
plt.plot(moyennes2)
plt.plot(moyennes3)

cloud terraceBOT
#

Hey @silk sun!

It looks like you're trying to paste code into this channel.

Discord has support for Markdown, which allows you to post code with full syntax highlighting. Please use these whenever you paste code, as this helps improve the legibility and makes it easier for us to help you.

To do this, use the following method:
```py
print('Hello, world!')
```

This will result in the following:

print('Hello, world!')```
You can **edit your original message** to correct your code block.
silk sun
#

here is what i've done

tawny ibex
silk sun
#

lol

#

you're so stressful ngl

#

can you calm down a bit please

#

or not help me anymore

tawny ibex
#

If you are still in class, you had better pay attention to the class.

silk sun
#

the class asked me to do that ๐Ÿ™‚

#

so i had to know how to do that

#

i was blocked

tawny ibex
#

?

silk sun
#

the class is finished

tawny ibex
#

What does that mean?

silk sun
#

it's franglish sorry

#

i'm going to send you my code

#

in a readable way

#

import numpy as np
import matplotlib.pyplot as plt

X=[]
n=200
pas=10
moyennes1=[]
variances1=[]
moyennes2=[]
variances2=[]
moyennes3=[]
for j in range(20):
    for i in range(10000):
        X=np.random.normal(0,1,20+10*j)
        T1=np.sum(X)/n
        T2=np.median(X)
        T3=(np.max(X)+np.min(X))/2
        moyenne1=np.mean(T1)
        moyenne2=np.mean(T2)
        moyenne3=np.mean(T3)
        
    moyennes1.append(moyenne1)
    moyennes2.append(moyenne2)
    moyennes3.append(moyenne3)
    
plt.plot(moyennes1)
plt.plot(moyennes2)
plt.plot(moyennes3)
#

T1, T2 and T3 are three estimators

#

for each of them i have to compute 10000 times a variable which is X

#

and the length of X varies from 20 to 200 with a step of 10

cloud terraceBOT
#
Python help channel closed

This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.