I'm trying to use py-script to show my own projects from github working. but it means that my functions need to access my github subfolders to work and I dont know how to...
This is the code I'm trying to use, it has a math lib reference that works fine, and my references to tables and tabelastoolkit lib that dont.
<div class="codigo">
<py-script>
import math
from https://github.com/capuadaniel/3d_science_plotter.git import base
def t_binomial(N, k, alfa = 0.05, uni_bi = 2, p = 0.5 ):
q = 1 - p
h = z = 0.5
if N > 25 and N*p*q >= 9:
z = (k + 0.5) - (N * p) / math.sqrt(N * p * q)
elif N <= 35:
z = float('0.'+tabelas.D[N][k])
else:
if k > N*p:
h = -0.5
z = ((k + h) - (N * p)) / math.sqrt(N * p * q)
z = tabelastoolkit.alfaconvert(z,'a') * uni_bi
p = alfa
if z < p:
return f'z= {z} é menor que o nivel de significancia p={p} estabelecido, favorecendo H1'
else:
return f'z= {z} é maior que o nivel de significancia p={p} estabelecido, favorecendo H0'
t_binomial(18, 8)
</py-script>
</div>
Of course the line "from https://github.com/capuadaniel/3d_science_plotter.git import base" is the key, anyone already made anithing in this way?