Last active
October 25, 2019 04:09
-
-
Save tfolkman/28af6bba04e37d7ebc385de56fc02e9c to your computer and use it in GitHub Desktop.
NamedTuple
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from collections import namedtuple | |
Features = namedtuple('Features', ['age', 'gender', 'name']) | |
row = Features(age=22, gender='male', name='Alex') | |
print(row.age) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment