knitr::opts_chunk$set( collapse = TRUE, comment = "#>" )
The get_embed
function retrieves embeddings based on provided input data. This vignette demonstrates the usage of the get_embed
function with example datasets included in the MUGS
package.
Ensure the MUGS
package is loaded before running the example:
library(MUGS)
Load the example datasets for the get_embed
function:
set.seed(1) S <- matrix(rnorm(100^2), 100, 100) library(rsvd) svd <- rsvd(S, 20)
get_embed
FunctionRun the get_embed
function to extract embeddings from the data:
# Example usage of get_embed U <- get_embed(svd, d=10, normalize=TRUE)
Explore the structure and key components of the output:
# View the structure of the output str(U) # Display the first few rows of the results cat("\nEmbedding Results (first 5 rows):\n") print(head(U, 5))
U.1
and S.1
are properly formatted matrices or data frames.This vignette demonstrated the use of the get_embed
function to retrieve embeddings from input data. Use this function to process your data and extract meaningful embeddings for further applications.
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.