Skip to contents

This represents scaled and merged x-ray data from one crystal.

Usage

merged_reflections(ruc = NULL, csym = NULL, records = NULL, dtypes = NULL)

Arguments

ruc

An object of class "rec_unit_cell" (which represents a reciprocal unit cell).

csym

An object of class "cryst_symm" (which represents a crystallographic symmetry group).

records

A data frame containing all reflections coming from the x-ray data collection on the crystal. This data frame must include at least the three Miller indices, H, K, L (of dtype "H").

dtypes

A character vector whose length is the same as the number of columns in 'records'. One character (a capital letter) is associated with each type of data. For example, a Miller index is of dtype "H"; a structure amplitude is of dtype "F"; an anomalous difference is of dtype "D"; etc (see details later).

Value

An object of class "merged_reflections". It is a named list of length 4 whose names are:

ruc

An object of class "rec_unit_cell".

csym

An object of class "cryst_symm".

records

A data frame containing the data.

dtypes

A character vector containing the type of data (Miller indices, structure factors, etc).

Details

If the constructor is used without arguments, the default object created will be create reflections for a cubic crystal with cell of side 10 angstroms, and symmetry P 2 3, up to 5 angstroms resolution. The only available columns will be of dtype "H", named H, K, L (the Miller indices), and of dtype "S", inverse resoluton, named S.

The possible dtypes are:

H

Miller index

S

Inverse resolution (1/angstroms)

J

Reflection intensity

F

Amplitude of a structure factor

D

Anomalous difference

Q

Standard deviation of J, F, D

G

Amplitude associated with a Friedel pair (F(+), F(-))

L

Standard deviation of G

K

Intensity associated with G (I(+), I(-))

M

Standard deviation of K

E

Amplitude of the normalised structure factors

P

Phase angle (in degrees)

W

Weight of some sort

A

Phase probability coefficients (Hendrickson-Lattman)

B

Batch number (from raw data)

I

Any other integer

R

Any other real

More values can become available in a future release.

Examples

# Create an orthorombic (default) cell
uc <- unit_cell(10,30,15)

# Create the related reciprocal cell
ruc <- create_rec_unit_cell(uc)

# Create symmetry (P n c 2)
csym <- cryst_symm(30)

# Create a few records (these include syst. absences)
records <- expand.grid(H=-2:2,K=-2:2,L=-2:2)
print(length(records[,1]))
#> [1] 125

# dtypes are all H
dtypes <- c("H","H","H")

# Create merged_reflections object with H, K, L
# Systematic absences have been eliminated
mrefs <- merged_reflections(ruc,csym,records,dtypes)
#> Systematic absences have been eliminated from 'records'.
print(length(mrefs$records[,1]))
#> [1] 109