Code Monkey home page Code Monkey logo

bsd-qbio4's People

Contributors

grahamas avatar meren avatar pcarbo avatar pjlarivi avatar sepalmer avatar stefanoallesina avatar steinrue avatar wj2 avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bsd-qbio4's Issues

my_factorial function in Basic Computing 2 cannot handle edge cases

Describe the bug
The my_factorial example function in Basic Computing 2 returns incorrect answers if the input is 0 or 1

To Reproduce
my_factorial <- function(a = 6){
if (as.integer(a) != a) {
print("Please enter an integer!")
} else {
tmp <- 1
for (i in 2:a){
tmp <- tmp * i
}
print(paste(a, "! = ", tmp, sep = ""))
}
}

my_factorial(1)
[1] "1! = 2"
my_factorial(0)
[1] "0! = 0"

FIX:
explicitly code in behavior in edge cases

changes to reproducibilty

Some changes that would make the reproducibility tutorial flow better:

  • Make the "Do one thing at a time" example more relatable and so easier to present (i.e. not involving foos)
  • Integrate the ticket generation into the seed section, so that the seed example that people compare is tickets rather than numbers
  • Reorganize so that students notice that their edits to make the code more readable (removing magic numbers etc.) would be easier if the copied code were in a function
  • Give repos explicit names, e.g. "writings" (not reprodicibility or origin)
  • Get rid of single-line if-else statement, as it is unnecessarily confusing
  • Include code example of dpois

New Tshirt Ideas

Use this issue to think about new t-shirt ideas for the next qbio:

  1. Escape to Cape Code

Page numbers in the workbook

Students seem frustrated with the pagination of the workbook.

Let's add some master page numbers throughout, perhaps in addition to the sub-section numbering.

We could alternatively add colored paper or tabs between the sections, but that might be prohibitively expensive to print.

File encoding doesn't work for some computers

Describe the bug
On keyboards set to a non-English setting, e.g. for Mandarin speaking users, files will be encoded with ASCII, which throws errors unless explicitly stated on some R commands.

To Reproduce
papers <- read.csv("~/BSD-QBio4/tutorials/basic_computing_2/data/citations/nature_neuroscience.csv", stringsAsFactors = FALSE)
papers$TitleLength <- nchar(papers$Title)
Error at [something]:
invalid multibyte string at [something]

FIX:
read csv with explicit file encoding, e.g.
papers <- read.csv("~/BSD-QBio4/tutorials/basic_computing_2/data/citations/nature_neuroscience.csv", stringsAsFactors = FALSE,fileEncoding='ASCII')

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.