mirror of
				https://asciireactor.com/otho/phy-4660.git
				synced 2025-11-04 06:38:02 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			513 lines
		
	
	
		
			18 KiB
		
	
	
	
		
			R
		
	
	
	
	
	
			
		
		
	
	
			513 lines
		
	
	
		
			18 KiB
		
	
	
	
		
			R
		
	
	
	
	
	
help(seq)
 | 
						|
seq(0,8191)
 | 
						|
dim(seq(0,8191)
 | 
						|
0
 | 
						|
dim(radium)
 | 
						|
dim(radium[1])
 | 
						|
(radium[1,1]
 | 
						|
(radium[1,0]
 | 
						|
0
 | 
						|
radium[1,0]
 | 
						|
radium[1,1]
 | 
						|
plot(radium[1,1])
 | 
						|
mean(radium)
 | 
						|
mean(radium[1])
 | 
						|
summary(radium)
 | 
						|
sd(radium)
 | 
						|
radium[1]
 | 
						|
sd(radium[1])
 | 
						|
sd(radium[V1])
 | 
						|
sapply(radium,mean)
 | 
						|
sapply(radium,sd)
 | 
						|
hist(radium)
 | 
						|
sapply(radium,hist)
 | 
						|
x <- seq_along(r)
 | 
						|
x <- seq_along(radium)
 | 
						|
x
 | 
						|
x <- seq_along(radium[V1])
 | 
						|
x <- seq_along(radium[1)
 | 
						|
x <- seq_along(radium[1])
 | 
						|
x
 | 
						|
radiu
 | 
						|
radium
 | 
						|
f <- function(par)
 | 
						|
{
 | 
						|
m <- par[1]
 | 
						|
sd <- par[2]
 | 
						|
k <- par[3]
 | 
						|
yhat <- k * exp(-0.5 * ((x - m)/sd)^2)
 | 
						|
sum((r - rhat)^2)
 | 
						|
}
 | 
						|
optim(c(15,2,1),f,method="BFGS",control=list(reltol=1e-9))
 | 
						|
f <- function(par)
 | 
						|
{
 | 
						|
m <- par[1]
 | 
						|
sd <- par[2]
 | 
						|
k <- par[3]
 | 
						|
yhat <- k * exp(-0.5 * ((x - m)/sd)^2)
 | 
						|
sum((radium - rhat)^2)
 | 
						|
}
 | 
						|
optim(c(15,2,1),f,method="BFGS",control=list(reltol=1e-9))
 | 
						|
f <- function(par)
 | 
						|
{
 | 
						|
m <- par[1]
 | 
						|
sd <- par[2]
 | 
						|
k <- par[3]
 | 
						|
yhat <- k * exp(-0.5 * ((x - m)/sd)^2)
 | 
						|
sum((radium - yhat)^2)
 | 
						|
}
 | 
						|
optim(c(15,2,1),f,method="BFGS",control=list(reltol=1e-9))
 | 
						|
help(unlist)
 | 
						|
help(data)
 | 
						|
data
 | 
						|
data()
 | 
						|
radium
 | 
						|
row
 | 
						|
row.names(radium)
 | 
						|
names(radium)
 | 
						|
help(row)
 | 
						|
Radium <- as.numeric(radium[1,])
 | 
						|
Radium
 | 
						|
Radium <- as.numeric(radium[2,])
 | 
						|
Radium
 | 
						|
Radium <- as.numeric(radium[1,])
 | 
						|
Radium <- as.numeric(radium[1])
 | 
						|
radium[1,
 | 
						|
radium[1,]
 | 
						|
radium[1,]
 | 
						|
radium[1]
 | 
						|
Radium <- as.numeric(radium[1])
 | 
						|
Radium <- as.numeric(radium[1,2])
 | 
						|
Radium
 | 
						|
Radium <- as.numeric(radium[1,1])
 | 
						|
Radium
 | 
						|
radium[1,1]
 | 
						|
radium[2,1]
 | 
						|
radium[2,]
 | 
						|
radium[1,]
 | 
						|
radium[0,]
 | 
						|
radium
 | 
						|
radium["V1"]
 | 
						|
radium["V1sdf"]
 | 
						|
radium["V1"]
 | 
						|
radium[,]
 | 
						|
radium[,1]
 | 
						|
radium[,0]
 | 
						|
radium[,1]
 | 
						|
radium[,2]
 | 
						|
radium[,]
 | 
						|
Radium <- as.numeric(radium[,])
 | 
						|
Radium
 | 
						|
plot(seq(0,8191),Radium)
 | 
						|
plot(seq_along(Radium),Radium)
 | 
						|
plot(radium)
 | 
						|
mean(radium_
 | 
						|
mean(radium)
 | 
						|
sapply(radium,mean)
 | 
						|
skewness
 | 
						|
library(fBasics)
 | 
						|
test=c(5,6,7,8,9)
 | 
						|
test
 | 
						|
test[1:3]=0
 | 
						|
test
 | 
						|
radium[,70:180]
 | 
						|
radium[70:180]
 | 
						|
radium[1,70:180]
 | 
						|
radium[,70:180]
 | 
						|
radium[,]
 | 
						|
radium[,][70:180]
 | 
						|
radium[,1:3]
 | 
						|
radium[,]1:3]
 | 
						|
radium[,][1:3]
 | 
						|
radium[,][90:180]
 | 
						|
radium[,][:180]
 | 
						|
radium[,][90]
 | 
						|
radium[,][70]
 | 
						|
radium[,]
 | 
						|
plot(radium[,])
 | 
						|
radium$V1
 | 
						|
plot(radium$v1)
 | 
						|
plot(radium$V1)
 | 
						|
library("MASS")
 | 
						|
fitdistr(radium,"
 | 
						|
fitdistr(radium,"normal")
 | 
						|
help(fitdistr)
 | 
						|
fitdistr(Radium,"normal")
 | 
						|
hist
 | 
						|
hist(radium)
 | 
						|
hist(Radium)
 | 
						|
hist(Radium,prob=TRUE)
 | 
						|
dput(radium)
 | 
						|
dput(Radium)
 | 
						|
plot(Radium)
 | 
						|
x <- seq_along(radium)
 | 
						|
y <- radium
 | 
						|
f
 | 
						|
f <- function(par)
 | 
						|
m <- par[1]
 | 
						|
sd <- par[2]
 | 
						|
k <- par[3]
 | 
						|
f = function(par)
 | 
						|
{
 | 
						|
m = par[1]
 | 
						|
sd = par[2]
 | 
						|
k = par[3]
 | 
						|
yhat = k * exp(-0.5 * ((x - m)/sd)^2)
 | 
						|
sum((y - yhat)^2)
 | 
						|
}
 | 
						|
optim(c(15,2,1),f,method="BFGS",control=list(reltol=1e-9)
 | 
						|
optim(c(15,2,1),f,method="BFGS",control=list(reltol=1e-9))
 | 
						|
optim(c(12,3,2),f,method="BFGS",control=list(reltol=1e-9))
 | 
						|
cal = read.table("AM_calibration_curve")
 | 
						|
cal
 | 
						|
summary(cal)
 | 
						|
help(read.table)
 | 
						|
cal = read.table("AM_calibration_curve",header=TRUE)
 | 
						|
cal
 | 
						|
plot(cal)
 | 
						|
cal$count
 | 
						|
plot(cal$count)
 | 
						|
Cal = cal$count
 | 
						|
Cal
 | 
						|
plot(Cal)
 | 
						|
skewness(Cal)
 | 
						|
f
 | 
						|
g = function(par)
 | 
						|
m = par[1]
 | 
						|
sd = par[2]
 | 
						|
g = function(par)
 | 
						|
m = par[1]
 | 
						|
g = function(par)
 | 
						|
{
 | 
						|
m = par[1]
 | 
						|
sd = par[2]
 | 
						|
k = par[3]
 | 
						|
yhat = k * exp(-0.5 * ((x - m)/sd)^2)
 | 
						|
sum((y - yhat)^2)
 | 
						|
}
 | 
						|
x = Cal
 | 
						|
x = seq_along(Cal)
 | 
						|
x
 | 
						|
y = Cal
 | 
						|
optim(c(12,3,2),f,method="BFGS",control=list(reltol=1e-9))
 | 
						|
tab = data.frame(x,y)
 | 
						|
plot(tab)
 | 
						|
(res <- nls( r ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=15,sigma=5,k=1) , data = tab))
 | 
						|
tabv
 | 
						|
tab
 | 
						|
(res <- nls( r ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=15,sigma=5,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=15,sigma=5,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=15,sigma=5,k=1) , data = tab))
 | 
						|
red
 | 
						|
res
 | 
						|
summar(res)
 | 
						|
summary(res)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=12,sigma=5,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=12,sigma=3,k=1) , data = tab))
 | 
						|
v <- summary(res)$parameters[,"Estimate"]
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7500,sigma=200,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7500,sigma=20,k=1) , data = tab))
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
summary(res)
 | 
						|
v <- summary(res)$parameters[,"Estimate"]
 | 
						|
plot(r~x, data=tab)
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=5,add=T,xlim=range(tab$x) )
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=3,add=T,xlim=range(tab$x) )
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x)
 | 
						|
function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2)
 | 
						|
v[3]*exp(-1/2*(x-v[1])^2/v[2]^2)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2))
 | 
						|
function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
help(plot)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),type=l)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),l)
 | 
						|
help plot
 | 
						|
help(plot)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),type="l")
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l")
 | 
						|
plot(cal)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l")
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l")
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l",add=TRUE)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l",add=T)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l",add="T)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l",add=T)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,type="l",add=T,xlim=range(tab$x))
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
help(plot_
 | 
						|
help(plot)
 | 
						|
help(plot)
 | 
						|
help(plot)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T)
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x))
 | 
						|
plot(y~x, data=tab)
 | 
						|
help(nls)
 | 
						|
gumbel
 | 
						|
library(gumbel)
 | 
						|
help(gumbel)
 | 
						|
??gumbel
 | 
						|
help(maxit)
 | 
						|
library(fitdistrplus)
 | 
						|
library(fitdist)
 | 
						|
fitdist
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7500,beta=50,) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7500,beta=50) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7500,beta=100) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7500,beta=1) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7000,beta=1) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7200,beta=10) , data = tab))
 | 
						|
plot(y~x, data=tab)
 | 
						|
v <- summary(res)$parameters[,"Estimate"]
 | 
						|
plot(function(x) (1/v[2])*exp((x-v[1])/v[2] - exp((x - v[1])/v[2]))
 | 
						|
plot(function(x) (1/v[2])*exp((x-v[1])/v[2] - exp((x - v[1])/v[2])),col=2,add=T,xlim=range(tab$x))
 | 
						|
function(x) (1/v[2])*exp((x-v[1])/v[2] - exp((x - v[1])/v[2]))
 | 
						|
(1/v[2])*exp((x-v[1])/v[2] - exp((x - v[1])/v[2]))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7200,beta=.1) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7200,beta=.15) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7200,beta=.01) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7200,beta=2) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=6800,beta=2) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=6900,beta=2) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=6950,beta=2) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7550,beta=2) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7550,beta=3) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7550,beta=4) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7550,beta=14) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7350,beta=14) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7350,beta=19) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7350,beta=10) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7250,beta=10) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7254,beta=10) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7254,beta=15) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7254,beta=19) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7254,beta=100) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), start=c(alpha=7254,beta=100) , data = tab))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((-x-alpha)/beta - exp((-x - alpha)/beta)), start=c(alpha=7254,beta=100) , data = tab))
 | 
						|
library(gumbel)
 | 
						|
help(fitdistr)
 | 
						|
help(fitdistr)
 | 
						|
fitdistr(x,"Gamma")
 | 
						|
fitdistr(x,"gamma")
 | 
						|
fitdistr(y,"gamma")
 | 
						|
fitdistr(y~x,"gamma")
 | 
						|
x
 | 
						|
1
 | 
						|
y
 | 
						|
help(fitdistr)
 | 
						|
x3 <- rweibull(100, shape = 4, scale = 100)
 | 
						|
x3
 | 
						|
fitdistr(y,"gamma")
 | 
						|
fitdistr(y,"weibull"")
 | 
						|
fitdistr(y,"weibull")
 | 
						|
help(fitdistr)
 | 
						|
fitdistr(y,"weibull")
 | 
						|
y
 | 
						|
fitdistr(y,"gamma")
 | 
						|
help(nls)
 | 
						|
help(nls.control)
 | 
						|
tab
 | 
						|
man(nls)
 | 
						|
help(nls)
 | 
						|
y
 | 
						|
help(~)
 | 
						|
help("~")
 | 
						|
help(formula)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=15,sigma=5,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=5,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , y))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
cal
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
help(nls)
 | 
						|
help(nls.control)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal, control=minFactor(0.0002))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal, control=minFactor(0.0002)))
 | 
						|
help(nls.control)
 | 
						|
help(nls.control)
 | 
						|
nls.control(minFactor=0.0001)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal).control(minFactor=0.0001))
 | 
						|
help(nls.control)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal).control(minFactor=1/2048))
 | 
						|
nls.control(minFactor=0.0001)
 | 
						|
nls.control
 | 
						|
1/1024
 | 
						|
nls.control(minFactor=0.0001); 
 | 
						|
nls.control(minFactor=0.0001) 
 | 
						|
nls.control(minFactor=0.0001) bls
 | 
						|
nls.control(minFactor=0.0001) nls
 | 
						|
nls.control(minFactor=0.0001) nls()
 | 
						|
nls.control(minFactor=0.0001); nls()
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal).control(minFactor=1/2048))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
nls.control(minFactor=0.0001); (res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
help(nls.control)
 | 
						|
nls.control(minFactor=1/2048)
 | 
						|
nls.control(minFactor=1/4096)
 | 
						|
nls.control(minFactor=0.0001); (res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
nls.control(minFactor=1/4096)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , cal))
 | 
						|
help(nls)
 | 
						|
help(nls)
 | 
						|
help(nls)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7200,sigma=50,k=1) , data = cal))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), cal, start=c(mu=7200,sigma=50,k=1)))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), cal, start=c(mu=7200,sigma=50,k=1),control=list(minFactor=1/4096)))
 | 
						|
v <- summary(res)$parameters[,"Estimate"]
 | 
						|
plot(y~x, data=tab)
 | 
						|
plot(function(x) v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,add=T,xlim=range(tab$x) )
 | 
						|
tab
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), data=y,start=c(alpha=7200,beta=10),control=list(minFactor=1/4096)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), y,start=c(alpha=7200,beta=10),control=list(minFactor=1/4096)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), cal,start=c(alpha=7200,beta=10),control=list(minFactor=1/4096)))
 | 
						|
res
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), cal,start=c(alpha=7200,beta=10)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), cal,start=c(alpha=7200,beta=1)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), cal,start=c(alpha=7200,beta=1),control=list(minFactor=1/4096)))
 | 
						|
help(nls.control)
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), cal,start=c(alpha=7200,beta=1),control=list(minFactor=1/4096,maxiter=100)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), cal,start=c(alpha=7200,beta=1),control=list(minFactor=1/4096,maxiter=200)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), data=y,start=c(alpha=7200,beta=1),control=list(minFactor=1/8192,maxiter=1000)))
 | 
						|
cal
 | 
						|
y
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), data=cal,start=c(alpha=7200,beta=1),control=list(minFactor=1/8192,maxiter=1000)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), data=cal,start=c(alpha=7200,beta=1),control=list(minFactor=1/16384,maxiter=1000)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), data=cal,start=c(alpha=7200,beta=1),control=list(minFactor=1/50000,maxiter=1000)))
 | 
						|
(res <- nls( y ~ (1/beta)*exp((x-alpha)/beta - exp((x - alpha)/beta)), data=cal,start=c(alpha=7800,beta=1),control=list(minFactor=1/50000,maxiter=1000)))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=15,sigma=5,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7500,sigma=50,k=1) , data = tab)))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7500,sigma=50,k=1) , data = tab)
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7500,sigma=50,k=1) , data = tab))
 | 
						|
(res <- nls( y ~ k*exp(-1/2*(x-mu)^2/sigma^2), start=c(mu=7800,sigma=50,k=1) , data = tab))
 | 
						|
help(write)
 | 
						|
v[3]*exp(-1/2*(x-v[1])^2/v[2]^2)
 | 
						|
write(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),file="calibration_gaussian")
 | 
						|
help(write)
 | 
						|
write(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),file="calibration_gaussian".ncolumns=1)
 | 
						|
write(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),file="calibration_gaussian",ncolumns=1)
 | 
						|
plot(cal)
 | 
						|
plot(x)
 | 
						|
plot(y)
 | 
						|
help(plot)
 | 
						|
plot(y,xlab="channel")
 | 
						|
plot(y,xlab="Channel")
 | 
						|
plot(y,xlab="Channel",ylab="Count")
 | 
						|
help(plot)
 | 
						|
help(axis)
 | 
						|
axis(1,labels=FALSe)
 | 
						|
axis(1,labels=FALSE)
 | 
						|
axis(1,labels=FALSE)
 | 
						|
axis(1,labels=TRUE)
 | 
						|
axis(2)
 | 
						|
box()
 | 
						|
rnorm
 | 
						|
require(stats)
 | 
						|
rnorm
 | 
						|
plot(1:4,rnorm(4),axes=FALSe)
 | 
						|
plot(1:4,rnorm(4),axes=FALSE)
 | 
						|
plot(1:4,rnorm(4),axes=FALSE)
 | 
						|
plot(1:4,rnorm(4),axes=FALSE)
 | 
						|
plot(1:4,rnorm(4),axes=FALSE)
 | 
						|
plot(1:4,rnorm(4),axes=FALSE)
 | 
						|
plot(1:4,rnorm(4),axes=FALSE)
 | 
						|
plot(y,xlab="Channel",ylab="Count")
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2))
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=red)
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2)
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2)
 | 
						|
plot(y,xlab="Channel",ylab="Count")
 | 
						|
plot(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2)
 | 
						|
plot(y,xlab="Channel",ylab="Count")
 | 
						|
points(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2)
 | 
						|
undo
 | 
						|
undo()
 | 
						|
cancel()
 | 
						|
plot(y,xlab="Channel",ylab="Count")
 | 
						|
help(lines)
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2)
 | 
						|
help(points)
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,lwd=2)
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=4)
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=1)
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=.5)
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,lwd=2)
 | 
						|
man(hist)
 | 
						|
help(hist)
 | 
						|
hist(x)
 | 
						|
hist(y)
 | 
						|
help(hist)
 | 
						|
help(hist,freq=TRUE)
 | 
						|
hist(y,freq=TRUE)
 | 
						|
hist(y)
 | 
						|
hist(y,freq=TRUE)
 | 
						|
help(hist,freq=TRUE)
 | 
						|
help(hist)
 | 
						|
hist(x~y,freq=TRUE)
 | 
						|
hist(x~y)
 | 
						|
x
 | 
						|
y
 | 
						|
hist(cal)
 | 
						|
hist(x)
 | 
						|
axis
 | 
						|
help(axis)
 | 
						|
axis(ylim=c(0,1000))
 | 
						|
axis(list(ylim=c(0,1000)))
 | 
						|
help(axis)
 | 
						|
hist(x,ylim=c(0,1000))
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=4,pch="x")
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=4,pch="-")
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=4,pch="─")
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,lwd=2)
 | 
						|
abline(v = 7913.63,col=3)
 | 
						|
abline(v = 7913.63,col=2)
 | 
						|
abline(v = 7913.63,col=1)
 | 
						|
abline(v = 7913.63,col=4)
 | 
						|
abline(v = 7913.63,col=5)
 | 
						|
abline(v = 7913.63,col=4,lwd=2)
 | 
						|
abline(v = 7813.63,col=4,lwd=2)
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=4,pch="─")
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,lwd=2)
 | 
						|
plot(y,xlab="Channel",ylab="Count",lwd=4,pch="─")
 | 
						|
lines(v[3]*exp(-1/2*(x-v[1])^2/v[2]^2),col=2,lwd=2)
 | 
						|
abline(v = 7813.63,col=4,lwd=2)
 | 
						|
dev.print(pdf,'calibration.pdf')
 | 
						|
q()
 |