Intersect: Function to compute the intersection between elements of two...

IntersectR Documentation

Function to compute the intersection between elements of two vectors

Description

Having as input two sets of elements represented by two vectors, the intersection between the two sets is performed and the corresponding vector is returned.

Usage

Intersect(sub1, sub2)

Arguments

sub1

first vector representing the first set

sub2

second vector representing the second set

Value

vector that stores the elements common to the two input vectors

Author(s)

Giorgio Valentini valentini@di.unimi.it

Examples

# Intesection between two sets of elements represented by vectors
s1 <- 1:10;
s2 <- 3:12;
Intersect(s1, s2)

mosclust documentation built on June 8, 2025, 11:23 a.m.