Learn R Programming

gdverse (version 1.3-3)

weight_assign: assign values by weight

Description

assign values by weight

Usage

weight_assign(x, w, list = FALSE)

Value

A numeric Vector.

Arguments

x

A numeric value

w

A weight vector

list

(optional) Return list or not. if list is TRUE, return a list, otherwise return a vector. Default is FALSE.

Examples

Run this code
weight_assign(0.875,1:3)

Run the code above in your browser using DataLab