Ten simple rules on writing clean and reliable open-source scientific software
Functional, usable, and maintainable open-source software is increasingly essential to scientific research, but there is a large variation in formal training for software development and maintainability. Here, we propose 10 “rules” centered on 2 best practice components: clean code and testing. Thes...
Guardado en:
Autores principales: | , , , , |
---|---|
Formato: | article |
Lenguaje: | EN |
Publicado: |
Public Library of Science (PLoS)
2021
|
Materias: | |
Acceso en línea: | https://doaj.org/article/ac9098b64f984d329777c3a0c38510bc |
Etiquetas: |
Agregar Etiqueta
Sin Etiquetas, Sea el primero en etiquetar este registro!
|
id |
oai:doaj.org-article:ac9098b64f984d329777c3a0c38510bc |
---|---|
record_format |
dspace |
spelling |
oai:doaj.org-article:ac9098b64f984d329777c3a0c38510bc2021-11-18T05:52:51ZTen simple rules on writing clean and reliable open-source scientific software1553-734X1553-7358https://doaj.org/article/ac9098b64f984d329777c3a0c38510bc2021-11-01T00:00:00Zhttps://www.ncbi.nlm.nih.gov/pmc/articles/PMC8584773/?tool=EBIhttps://doaj.org/toc/1553-734Xhttps://doaj.org/toc/1553-7358Functional, usable, and maintainable open-source software is increasingly essential to scientific research, but there is a large variation in formal training for software development and maintainability. Here, we propose 10 “rules” centered on 2 best practice components: clean code and testing. These 2 areas are relatively straightforward and provide substantial utility relative to the learning investment. Adopting clean code practices helps to standardize and organize software code in order to enhance readability and reduce cognitive load for both the initial developer and subsequent contributors; this allows developers to concentrate on core functionality and reduce errors. Clean coding styles make software code more amenable to testing, including unit tests that work best with modular and consistent software code. Unit tests interrogate specific and isolated coding behavior to reduce coding errors and ensure intended functionality, especially as code increases in complexity; unit tests also implicitly provide example usages of code. Other forms of testing are geared to discover erroneous behavior arising from unexpected inputs or emerging from the interaction of complex codebases. Although conforming to coding styles and designing tests can add time to the software development project in the short term, these foundational tools can help to improve the correctness, quality, usability, and maintainability of open-source scientific software code. They also advance the principal point of scientific research: producing accurate results in a reproducible way. In addition to suggesting several tips for getting started with clean code and testing practices, we recommend numerous tools for the popular open-source scientific software languages Python, R, and Julia.Haley Hunter-ZinckAlexandre Fioravante de SiqueiraVáleri N. VásquezRichard BarnesCiera C. MartinezPublic Library of Science (PLoS)articleBiology (General)QH301-705.5ENPLoS Computational Biology, Vol 17, Iss 11 (2021) |
institution |
DOAJ |
collection |
DOAJ |
language |
EN |
topic |
Biology (General) QH301-705.5 |
spellingShingle |
Biology (General) QH301-705.5 Haley Hunter-Zinck Alexandre Fioravante de Siqueira Váleri N. Vásquez Richard Barnes Ciera C. Martinez Ten simple rules on writing clean and reliable open-source scientific software |
description |
Functional, usable, and maintainable open-source software is increasingly essential to scientific research, but there is a large variation in formal training for software development and maintainability. Here, we propose 10 “rules” centered on 2 best practice components: clean code and testing. These 2 areas are relatively straightforward and provide substantial utility relative to the learning investment. Adopting clean code practices helps to standardize and organize software code in order to enhance readability and reduce cognitive load for both the initial developer and subsequent contributors; this allows developers to concentrate on core functionality and reduce errors. Clean coding styles make software code more amenable to testing, including unit tests that work best with modular and consistent software code. Unit tests interrogate specific and isolated coding behavior to reduce coding errors and ensure intended functionality, especially as code increases in complexity; unit tests also implicitly provide example usages of code. Other forms of testing are geared to discover erroneous behavior arising from unexpected inputs or emerging from the interaction of complex codebases. Although conforming to coding styles and designing tests can add time to the software development project in the short term, these foundational tools can help to improve the correctness, quality, usability, and maintainability of open-source scientific software code. They also advance the principal point of scientific research: producing accurate results in a reproducible way. In addition to suggesting several tips for getting started with clean code and testing practices, we recommend numerous tools for the popular open-source scientific software languages Python, R, and Julia. |
format |
article |
author |
Haley Hunter-Zinck Alexandre Fioravante de Siqueira Váleri N. Vásquez Richard Barnes Ciera C. Martinez |
author_facet |
Haley Hunter-Zinck Alexandre Fioravante de Siqueira Váleri N. Vásquez Richard Barnes Ciera C. Martinez |
author_sort |
Haley Hunter-Zinck |
title |
Ten simple rules on writing clean and reliable open-source scientific software |
title_short |
Ten simple rules on writing clean and reliable open-source scientific software |
title_full |
Ten simple rules on writing clean and reliable open-source scientific software |
title_fullStr |
Ten simple rules on writing clean and reliable open-source scientific software |
title_full_unstemmed |
Ten simple rules on writing clean and reliable open-source scientific software |
title_sort |
ten simple rules on writing clean and reliable open-source scientific software |
publisher |
Public Library of Science (PLoS) |
publishDate |
2021 |
url |
https://doaj.org/article/ac9098b64f984d329777c3a0c38510bc |
work_keys_str_mv |
AT haleyhunterzinck tensimplerulesonwritingcleanandreliableopensourcescientificsoftware AT alexandrefioravantedesiqueira tensimplerulesonwritingcleanandreliableopensourcescientificsoftware AT valerinvasquez tensimplerulesonwritingcleanandreliableopensourcescientificsoftware AT richardbarnes tensimplerulesonwritingcleanandreliableopensourcescientificsoftware AT cieracmartinez tensimplerulesonwritingcleanandreliableopensourcescientificsoftware |
_version_ |
1718424748039340032 |