mistnet2 Neural Networks with Latent Random Variables in R Fit models with both complex nonlinearities (using neural networks) as well as structured outputs (using graphical models).