Advertisement
Guest User

Untitled

a guest
Mar 18th, 2019
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. import pandas as pd
  2.  
  3.  
  4. def main():
  5. df = pd.DataFrame({'product_id': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11],
  6. 'product_type': ['shirt', 'shirt', 'shirt', 'shirt', 'shirt', 'hat', 'hat', 'hat', 'hat', 'hat', 'hat', ],
  7. 'color': [None, None, None, 'red', 'blue', None, 'blue', 'blue', 'blue', 'red', 'red', ],
  8. 'size': [None, 's', 'xl', None, None, 's', None, 's', 'xl', None, 'xl', ],
  9. })
  10. print df
  11.  
  12. if __name__ == '__main__':
  13. main()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement