Skip to main content Accessibility help
×
Hostname: page-component-848d4c4894-ttngx Total loading time: 0 Render date: 2024-05-01T12:05:26.383Z Has data issue: false hasContentIssue false

6 - Files

Published online by Cambridge University Press:  05 February 2015

Tim J. Stevens
Affiliation:
MRC Laboratory of Molecular Biology, Cambridge
Wayne Boucher
Affiliation:
University of Cambridge
Get access

Summary

Computer files

A computer file is a means by which data is stored on a permanent basis, or at least until it is deleted. It is held in a place such as a hard disk drive or removable storage device that is separate from the active, temporary memory of a computer. While the active memory may hold the current program and an amount of data, files represent a larger archive of stored data and the general idea is that this should survive when the computer is switched off. Parts of this saved data may be copied into the active memory as required. Loading data from files (which may be stored locally or transmitted via a network) places data into the active memory so that it can be worked upon efficiently. This data might be the code for a computer program which can then be executed to do a job. Naturally we save program instruction code as a file so that it may be used as many times as desired, without having to rewrite anything.

This chapter will focus on data files that store information for programs to work with, rather than the program files themselves, given that we can trust the Python interpreter to handle the loading and running of Python code. We will show how data can be read into a program and written out from a program, e.g. to and from files stored on disk. Such data files come in a large variety of shapes, sizes and forms (unlike Python files, which conform to a single, precise standard). Information can be stored in an endless number of ways, sometimes at the whim of the programmer, but fortunately in the spirit of cooperation (including mutual financial interest) particular types of data are often stored in a standardised way, with a known specification.

Type
Chapter
Information
Python Programming for Biology
Bioinformatics and Beyond
, pp. 78 - 99
Publisher: Cambridge University Press
Print publication year: 2015

Access options

Get access to the full version of this content by using one of the access options below. (Log in options will check for institutional or personal access. Content may require purchase if you do not have access.)

Save book to Kindle

To save this book to your Kindle, first ensure coreplatform@cambridge.org is added to your Approved Personal Document E-mail List under your Personal Document Settings on the Manage Your Content and Devices page of your Amazon account. Then enter the ‘name’ part of your Kindle email address below. Find out more about saving to your Kindle.

Note you can select to save to either the @free.kindle.com or @kindle.com variations. ‘@free.kindle.com’ emails are free but can only be saved to your device when it is connected to wi-fi. ‘@kindle.com’ emails can be delivered even when you are not connected to wi-fi, but note that service fees apply.

Find out more about the Kindle Personal Document Service.

  • Files
  • Tim J. Stevens, MRC Laboratory of Molecular Biology, Cambridge, Wayne Boucher, University of Cambridge
  • Book: Python Programming for Biology
  • Online publication: 05 February 2015
  • Chapter DOI: https://doi.org/10.1017/CBO9780511843556.007
Available formats
×

Save book to Dropbox

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Dropbox.

  • Files
  • Tim J. Stevens, MRC Laboratory of Molecular Biology, Cambridge, Wayne Boucher, University of Cambridge
  • Book: Python Programming for Biology
  • Online publication: 05 February 2015
  • Chapter DOI: https://doi.org/10.1017/CBO9780511843556.007
Available formats
×

Save book to Google Drive

To save content items to your account, please confirm that you agree to abide by our usage policies. If this is the first time you use this feature, you will be asked to authorise Cambridge Core to connect with your account. Find out more about saving content to Google Drive.

  • Files
  • Tim J. Stevens, MRC Laboratory of Molecular Biology, Cambridge, Wayne Boucher, University of Cambridge
  • Book: Python Programming for Biology
  • Online publication: 05 February 2015
  • Chapter DOI: https://doi.org/10.1017/CBO9780511843556.007
Available formats
×