Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

franke.data

Test datasets from Franke for interpolation of scattered data


Description

franke.data generates the test datasets from Franke, 1979, see references.

Usage

franke.data(fn = 1, ds = 1, data)
franke.fn(x, y, fn = 1)

Arguments

fn

function number, from 1 to 5.

x

'x' value

y

'y' value

ds

data set number, from 1 to 3. Dataset 1 consists of 100 points, dataset 2 of 33 points and dataset 3 of 25 points scattered in the square [0,1]x[0,1]. (and partially slightly outside).

data

A list of dataframes with 'x' and 'y' to choose from, dataset franke should be used here.

Details

These datasets are mentioned in Akima, (1996) as a testbed for the irregular scattered data interpolator.

Franke used the five functions:

0.75*exp(-((9*x-2)^2+(9*y-2)^2)/4)+ 0.75*exp(-((9*x+1)^2)/49-(9*y+1)/10)+ 0.5*exp(-((9*x-7)^2+(9*y-3)^2)/4)- 0.2*exp(-(9*x-4)^2-(9*y-7)^2)

(tanh(9*y-9*x)+1)/9

(1.25+cos(5.4*y))/(6*(1+(3*x-1)^2))

exp(-81*((x-0.5)^2+(y-0.5)^2)/16)/3

exp(-81*((x-0.5)^2+(y-0.5)^2)/4)/3

sqrt(64-81*((x-0.5)^2+(y-0.5)^2))/9-0.5

and evaluated them on different more or less dense grids over [0,1]x[0,1].

Value

A data frame with components

x

'x' coordinate

y

'y' coordinate

z

'z' value

Note

The datasets have to be generated via franke.data before use, the dataset franke only contains a list of 3 dataframes of 'x' and 'y' coordinates for the above mentioned irregular grids. Do not forget to load the franke dataset first.

The 'x' and 'y' values have been taken from Akima (1996).

Author(s)

Albrecht Gebhardt <albrecht.gebhardt@aau.at>, Roger Bivand <roger.bivand@nhh.no>

References

FRANKE, R., (1979). A critical comparison of some methods for interpolation of scattered data. Tech. Rep. NPS-53-79-003, Dept. of Mathematics, Naval Postgraduate School, Monterey, Calif.

Akima, H. (1996). Algorithm 761: scattered-data surface fitting that has the accuracy of a cubic polynomial. ACM Transactions on Mathematical Software 22, 362–371.

See Also

Examples

## generate Frankes data set for function 2 and dataset 3:
data(franke)
F23 <- franke.data(2,3,franke)
str(F23)

interp

Interpolation Methods

v1.0-33
GPL (>= 2)
Authors
Albrecht Gebhardt [aut, cre, cph] (...), Roger Bivand [aut], David Sinclair [aut, cph]
Initial release
2020-01-07

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.