This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function addNavTracking() { | |
let parentNavs = document.querySelectorAll(".header-navigation li.menu-item"); | |
if (parentNavs.length) { | |
parentNavs.forEach(item => { | |
let label = item.querySelector("a").textContent; | |
if (label) { | |
item.addEventListener("click", () => { | |
ga("send", "event", "Menu-Nav", "click", label); | |
}); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os | |
import csv | |
DATADIR = "C:\Users\User\Downloads\HavasLynx" | |
DATAFILE = "tin00028.tsv" | |
EUCODES = "2letterEU.txt" | |
OUTFILE = "internetuse_EU.csv" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# write out table with data | |
write.table(merged_data, file='merged_data.tsv', quote=FALSE, sep='\t') | |
# open multiple datasets | |
temp = list.files(pattern="*.tsv") | |
gsub('.stv','',temp) | |
gsub('_output.tsv','_abundance',temp) | |
temp2 <- gsub('_output.tsv','_abundance',temp) | |
df <- read.table(temp[1]) | |
df <- read.table(temp[1],col.names=c('ID','T','P',temp2[1])) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ANOVA: ANALYSIS OF VARIANCE | |
# Regression and ANOVA are identical approaches except for the nature of the explanatory variables | |
# STATISTICAL BACKGORUND | |
# The emphasis of ANOVA is on hypothesis testing | |
# To estimate means and standard errors of differences between means | |
# Comparing two means by t-test: (difference between two means)/standard error of the difference -> compare with critical value | |
# In ANOVA we compare 3 or more means |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CHAPTER 7 | |
# LINEAR REGRESSION | |
reg.data <- read.csv("c:\\MSc\\Statistics\\Data\\tannin.csv") | |
attach(reg.data) | |
names(reg.data) | |
plot(tannin,growth,pch=21,bg="blue") | |
# LINEAR REGRESSION IN R | |
lm(growth∼tannin) | |
abline(lm(growth∼tannin),col="green") | |
fitted <- predict(lm(growth∼tannin)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# CHAPTER 6: | |
# TWO SAMPLES | |
# The classical tests: | |
# - Comparing two variances: Fisher's F test | |
var.test | |
# - Comparing two sample means with normal errors: Student's t test | |
t.test | |
# - Comparing two means with non-normal errors: Wilcoxon's test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use diagnostics; | |
use strict; | |
use warnings; | |
use Getopt::Long; | |
# Defining bin size and parameters | |
print "Enter file name:\n"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env perl | |
package ProNTo::IonStats; | |
use diagnostics; | |
use strict; | |
use warnings; | |
use Getopt::Long; | |
use Exporter; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use diagnostics; | |
use strict; | |
use warnings; | |
use Getopt::Long; | |
# Defining bin size and parameters | |
my $data = "table.tsv"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package session01; | |
import java.util.Scanner; | |
public class calc { | |
public static void main(String[] args) { | |
Scanner keyboard = new Scanner(System.in); | |
NewerOlder