Please enable JavaScript.
Coggle requires JavaScript to display documents.
working with text files - Coggle Diagram
working with text files
text files = flat files = ASCII file
squence of lines electronic text; each line = squence characters
end of line character
easy transfer of data
do not contain metadata (only contains text data)
file formats: json, xml, csv, txt, xlsx
text files
plain text file
rich text file/ docs
characters
separator: chars.seperate.value
eol = newline chars = line ending = line break \n
end of files (eof): no more chars.contain in text file
flat files
binary file
data structure
structured
tabular form
can be stored in dtabase
e.g excel, sql, pandas df
semi- structured
unstructured
e.g video, audio, photos
fixed-with data file
flat files contain fixed-width data formatting
naming conventions
UpperCamelCase
first letter is capital
used to name column name
lowerCamelCase
first letter first word = lower case
snake_case = lowercase_seperated_by_underscore
Kebab-case
DON'T use space
importing data with numpy
np.loadtxt()
data is ready to be directly imported and used
np.genfromtxt()
function create datasets from the text file