예제 #1
0
# my_lambdata/my_script

import pandas

from my_lambdata.my_mod import enlarge

print("Happy Tuesday Night")

df = pandas.DataFrame({"x": [1, 2, 3], "y": [4, 5, 6]})
print(df.head())

x = 5
print("ENLARGE", x, "TO", enlarge(x))
예제 #2
0
def test_enlarge():
    #self.assertEqual(enlarge(5),500)
    assert enlarge(5) == 500
예제 #3
0
 def test_enlarge(self):
     self.assertEqual(enlarge(5), 500)
예제 #4
0
import pandas as pd
from my_lambdata.my_mod import enlarge

print("HELLO")

df = pd.DataFrame({"a": [1, 2, 3], "b": [4, 5, 6]})

print(df.head())

print(enlarge(df["a"].sum()))
예제 #5
0
# my_script.py

from pandas import DataFrame
from my_lambdata.my_mod import enlarge

print('Hello World')

df = DataFrame({'a': [1, 2, 3], 'b': [4, 5, 6]})
print(df.head())

x = 11
print('Number', x)
print('Enlarged number', enlarge(x))

# df = pandas.DataFrame({'state':['CT', 'CO', 'CA', 'CA', 'TX']})
# print(df.head())

# print("--------------")
예제 #6
0
 def test_enlarge(self):
     """
     Unit test that the enlarge function in the my_mod file is working properly
     """
     self.assertEqual(enlarge(5), 500)
예제 #7
0
# my_lambdata/my_script.py
import pandas
from my_lambdata.my_mod import enlarge
print("HELLO WORLD")
df = pandas.DataFrame({"state": ["CT", "CO", "CA", "TX"]})
print(df.head())
print("-----------------")
x = 5
print("NUMBER", x)
print("ENLARGED NUMBER", enlarge(x))  # invoking our function!!
 def test_enlarge(self):
     self.assertEqual(enlarge(9), 900)
 def test_upper(self):
     self.assertEqual(enlarge(4), 400)
예제 #10
0
import pandas

from my_lambdata.my_mod import enlarge


print('Hello world uWu')

df = pandas.DataFrame({"state": ['CT', 'CO', 'CA', 'TX']})
print(df.head())

print(enlarge(9))
예제 #11
0
# my_lambdata/my_script.py

import pandas

from my_lambdata.my_mod import enlarge

print("Happy Whatever Day")

df = pandas.DataFrame({"x": [1, 2, 3], "y": [4, 5, 6]})
print(df.head())

x = 5
print("Enlarge", x, "TO", enlarge(x))
예제 #12
0
 def test_upper(self):
     self.assertEqual(enlarge(3), 300)
예제 #13
0
파일: my_script.py 프로젝트: dataabyss/dbld
import pandas

from my_lambdata.my_mod import enlarge

print('HAPPY TUESDAY NIGHT.')

df = pandas.DataFrame({'x': [1, 2, 3], 'y': [4, 5, 6]})
print(df.head())

x = 5
print('ENLARGE', x, 'TO', enlarge(x))
예제 #14
0
def test_upper():
    assert enlarge(3) == 300
예제 #15
0
from my_lambdata.my_mod import enlarge

print("Hello")

print(enlarge(8))

y = (enlarge(8))
예제 #16
0

from my_lambdata.my_mod import enlarge

print('Hello World.')
x = 100
print('x: ', x)
print('Enlarged x: ', enlarge(x))
예제 #17
0
# my_script.py

from pandas import DataFrame
#from my_mod import enlarge # this works
from my_lambdata.my_mod import enlarge

print("HELLO")

df = DataFrame({"a": [1, 2, 3], "b": [4, 5, 6]})
print(df.head())

x = 11
print(enlarge(x))
예제 #18
0
import unittest

from my_lambdata.my_mod import enlarge

x = 5
print(x, "Enlarge", enlarge(x))


class TestMyMod(unittest.TestCase):
    def test_enlarge(self):
        self.assertEqual(enlarge(5), 500)


if __name__ == '__main__':
    unittest.main()
예제 #19
0
#from my_mod import enlarge
from pandas import DataFrame

from my_lambdata.my_mod import enlarge

print("HELLO")

print(enlarge(8))


df = DataFrame({"state": ["CT", "CO", "CA", "TX"]})
print(df.head())
예제 #20
0
# Import enlarge and invoke enlarge
# Do not import the entire script (if __name__ == "__main__"...)

# from my_mod import enlarge

# Sometimes you may need this
# Will need an init file AND
# Run as '''python -m my_lambdata.hello''' (modular approach)
from my_lambdata.my_mod import enlarge

print('HELLO!')

print(enlarge(10))
예제 #21
0
# my_lambdata/my_script.py
from my_lambdata.my_mod import enlarge
import pandas
print("Hello")

df = pandas.DataFrame({"state": ["CT", "CO", "AZ"]})
print(df.head())

print("---------")

x = 5
print("num", x)
print("enlarged num", enlarge(x))
예제 #22
0
import pandas

#import my_mod
#from my_mod import enlarge # works
from my_lambdata.my_mod import enlarge

print("HELLO WORLD")

print(2+2)

df = pandas.DataFrame({"a":[1,2,3],"b":[4,5,6]})
print(df.head())


y = 9
print(enlarge(y))
예제 #23
0


import pandas

from my_lambdata.my_mod import enlarge, fib, fib2
from my_lambdata 

print("HELLO WORLD")

df = pandas.DataFrame({"state": ["CT", "CO", "CA", "TX"]})
print (df.head())

print("-------------")


x = 5
print("NUMBER", x)
print("ENLARGED NUMBER", enlarge(x))
예제 #24
0
from pandas import DataFrame
from my_lambdata.my_mod import enlarge  #this works

print('Hello')

df = DataFrame({'a': [1, 2, 3], 'b': [4, 5, 6]})

print(df.head())

x = 11
print(enlarge(x))  #importing only enlarge function
#if we use from my_mod import enlarge without "if __name__ == "__main__":"
# then the entire file my_mod will be executed