% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/variationalSequences.R
\name{variationalSequences}
\alias{variationalSequences}
\title{Generate Similar Sequences using Variational Autoencoder}
\usage{
variationalSequences(
  input.sequences,
  encoder.function = "onehotEncoder",
  aa.method.to.use = NULL,
  number.of.sequences = 100,
  encoder.hidden.dim = c(128, 64),
  decoder.hidden.dim = NULL,
  latent.dim = 16,
  batch.size = 16,
  epochs = 50,
  learning.rate = 0.001,
  epsilon.std = 1,
  call.threshold = 0.2,
  activation.function = "relu",
  optimizer = "adam",
  disable.eager.execution = FALSE,
  sequence.dictionary = amino.acids,
  verbose = TRUE
)
}
\arguments{
\item{input.sequences}{The amino acid or nucleotide sequences to use}

\item{encoder.function}{The method to prepare the sequencing information - 
"onehotEncoder" or "propertyEncoder"}

\item{aa.method.to.use}{The method or approach to use for the conversion:
\itemize{
  \item{Individual sets: atchleyFactors, crucianiProperties, FASGAI, kideraFactors, MSWHIM,
  ProtFP, stScales, tScales, VHSE, zScales"}
  \item{Multiple Sets: c("atchleyFactors", "VHSE") }
}}

\item{number.of.sequences}{Number of sequences to generate}

\item{encoder.hidden.dim}{A vector of the neurons to use in the hidden layers
for the encoder portion of the model}

\item{decoder.hidden.dim}{A vector of the neurons to use in the hidden layers 
for the decoder portion of the model. If NULL assumes symmetric autoencoder}

\item{latent.dim}{The size of the latent dimensions}

\item{batch.size}{The batch size to use for VAE training}

\item{epochs}{The number of epochs to use in VAE training}

\item{learning.rate}{The learning rate to use in VAE training}

\item{epsilon.std}{The epsilon to use in VAE training}

\item{call.threshold}{The relative strictness of sequence calling
with higher values being more stringent}

\item{activation.function}{The activation for the dense connected layers}

\item{optimizer}{The optimizer to use in VAE training}

\item{disable.eager.execution}{Disable the eager execution parameter for
tensorflow.}

\item{sequence.dictionary}{The letters to use in sequence mutation
(default are all amino acids)}

\item{verbose}{Print messages corresponding to the processing step}
}
\value{
A vector of mutated sequences
}
\description{
Use this to simulate sequences using a variational 
autoencoder (VAE) and perturbation of the probability distributions.
}
\examples{
\dontrun{
sequences <- generateSequences(prefix.motif = "CAS",
                               suffix.motif = "YF",
                               number.of.sequences = 100,
                               min.length = 8,
                               max.length = 16)

new.sequences <- variationalSequences(sequences, 
                                      encoder.function = "onehotEncoder",
                                      encoder.hidden.dim = c(256, 128),
                                      latent.dim = 16,
                                      batch.size = 16)
}
}
