duplicates = multiple editions
A Classical Introduction to Modern Number Theory, Kenneth Ireland Michael Rosen
A Classical Introduction to Modern Number Theory, Kenneth Ireland Michael Rosen
fun is_older (day1 : int*int*int, day2 : int*int*int) = | |
if (#1 day1) < (#1 day2) | |
then true | |
else if (((#2 day1) < (#2 day2)) andalso ((#1 day1) = (#1 day2))) | |
then true | |
else if (((#3 day1) < (#3 day2)) andalso ((#2 day1) = (#2 day2)) andalso ((#1 day1) = (#1 day2))) | |
then true | |
else false | |
complete <- function(directory, id = 1:332) { | |
## 'directory' is a character vector of length 1 indicating | |
## the location of the CSV files | |
## 'id' is an integer vector indicating the monitor ID numbers | |
## to be used | |
## Return a data frame of the form: | |
## id nobs | |
## 1 117 |
--- | |
name: ggplotly | |
layout: post | |
title: Make your ggplots shareable, collaborative, and with D3 | |
date: 2014-04-17 | |
author: Matt Sundquist | |
authorurl: https://plot.ly/team | |
tags: | |
- R | |
- API |
best <- function(state, outcome) { | |
data <- read.csv(file='outcome-of-care-measures.csv', colClasses = 'character') | |
if(!any(state == data$State)) { | |
stop('invalid state') | |
} | |
if(outcome == 'heart attack') { | |
i <- 11 |
.DS_STORE |
import requests | |
import csv | |
import sys | |
# get me all active players | |
url_allPlayers = ("http://stats.nba.com/stats/commonallplayers?IsOnlyCurrentSeason" | |
"=0&LeagueID=00&Season=2015-16") | |
#request url and parse the JSON |
fun number_before_reaching_sum (sum : int, xs : int list) = | |
if null xs then 0 | |
(*else if null (tl xs) then 1*) | |
else if hd xs > sum then 0 | |
else | |
let fun helper (i : int, partial_sum : int, tl_xs : int list) = | |
if partial_sum < 0 then i | |
else | |
helper(i + 1, partial_sum - hd tl_xs, tl tl_xs) | |
in |
rankall <- function(outcome, num = "best") { | |
data <- read.csv(file="outcome-of-care-measures.csv", colClasses = 'character') | |
if(outcome == 'heart attack') { | |
i <- 11 | |
} | |
else if(outcome == 'heart failure') { | |
i <- 17 | |
} | |
else if(outcome == 'pneumonia') { |