AFMImage-class {AFM}R Documentation

AFM image class

Description

A S4 class to store and manipulate images from Atomic Force Microscopes.

Usage

AFMImage(
  data,
  samplesperline,
  lines,
  hscansize,
  vscansize,
  scansize,
  fullfilename
)

## S4 method for signature 'AFMImage'
initialize(
  .Object,
  data,
  samplesperline,
  lines,
  hscansize,
  vscansize,
  scansize,
  fullfilename
)

AFMImage(
  data,
  samplesperline,
  lines,
  hscansize,
  vscansize,
  scansize,
  fullfilename
)

Arguments

data

($x,$y,$h): a data.table storing the coordinates of the sample and the measured heights

samplesperline

number of samples per line (e.g.: 512)

lines

number of line (e.g.: 512)

hscansize

horizontal size of scan usualy in nanometer (e.g.: hscansize=1000 for a scan size of 1000 nm)

vscansize

vertical size of scan usualy in nanometer (e.g.: vscansize=1000 for a scan size of 1000 nm)

scansize

if hscansize equals vscansize, scansize is the size of scan usualy in nanometer (e.g.: scansize=1000 for a scan size of 1000 nm)

fullfilename

directory and filename on the disk (e.g.: /users/ubuntu/flatten-image.txt)

.Object

an AFMImage object

Slots

data

($x,$y,$h): a data.table storing the coordinates of the sample and the measured heights

samplesperline

number of samples per line (e.g.: 512)

lines

number of line (e.g.: 512)

hscansize

horizontal size of scan usualy in nanometer (e.g.: hscansize=1000 for a scan size of 1000 nm)

vscansize

vertical size of scan usualy in nanometer (e.g.: vscansize=1000 for a scan size of 1000 nm)

scansize

if hscansize equals vscansize, scansize is the size of scan usualy in nanometer (e.g.: scansize=1000 for a scan size of 1000 nm)

fullfilename

directory and filename on the disk (e.g.: /users/ubuntu/flatten-image.txt)

Author(s)

M.Beauvais

Examples

## Not run: 
library(AFM)
library(data.table)

# create a 128 pixels by 128 pixels AFM image
Lines=128
Samplesperline=128
fullfilename="RandomFakeAFMImage"
# the size of scan is 128 nm
ScanSize=128
# the heights is a normal distribution in nanometers
nm<-c(rnorm(128*128, mean=0, sd=1 )) 

scanby<-ScanSize/Samplesperline
endScan<-ScanSize*(1-1/Samplesperline)
RandomFakeAFMImage<-AFMImage(
     data = data.table(x = rep(seq(0,endScan, by= scanby), times = Lines),
                       y = rep(seq(0,endScan, by= scanby), each = Samplesperline), 
                       h = nm),
     samplesperline = Samplesperline, lines = Lines, 
     vscansize = ScanSize, hscansize = ScanSize, scansize = ScanSize, 
     fullfilename = fullfilename )

## End(Not run)

[Package AFM version 2.0 Index]