Learn R Programming

kazaam (version 0.1-0)

lm_coefs: Linear Model Coefficients

Description

Coefficients of the linear model.

Usage

lm_coefs(x, y, tol = 1e-07)

Arguments

x, y

The input data x and response y. Each must be a shaq, and each must be distributed in an identical fashion. See the details section for more information.

tol

Numerical tolerance for deciding rank.

Value

A regular vector.

Communication

The operation has the same communication as

Details

The model is fit using a QR factorization of the input x. At this time, that means

Both of x and y must be distributed in an identical fashion. This means that the number of rows owned by each MPI rank should match, and the data rows x and labels y should be aligned. Additionally, each MPI rank should own at least one row. Ideally they should be load balanced, so that each MPI rank owns roughly the same amount of data.

See Also

glms

Examples

Run this code

library(kazaam)
comm.set.seed(1234, diff=TRUE)

x = ranshaq(rnorm, 10, 3)
y = ranshaq(runif, 10)

fit = lm_coefs(x, y)
comm.print(fit)

finalize()


Run the code above in your browser using DataLab