Documentation/Nodes/Visualization

Visualization Nodes

Comprehensive visualization tools including 20+ plot types, interactive molecular viewers, and publication-ready scientific charts for data analysis and presentation.

Available Plot Categories

Statistical Plots

Basic statistical visualizations

HistogramScatterLineBarBoxViolinKDEECDF

Scientific Plots

Specialized scientific visualizations

VolcanoVennHeatmapPair PlotRadarBubble

3D Plots

Three-dimensional visualizations

3D Scatter3D Surface3D Line

Molecular Viewers

Chemical structure visualization

2D Structure3D ViewerInteraction Maps

Node Reference

Detailed documentation for visualization and plotting nodes in Bioshift.

Structure Draw 2D

Generate 2D molecular structure depictions using RDKit

Type: structure_draw_2dCategory: Molecular Visualization

Key Features

  • High-quality 2D depictions
  • Atom/bond highlighting
  • Grid layout for multiple molecules
  • SVG vector output
  • Customizable drawing options

Input Ports

moleculesmolecules

RDKit molecule objects to draw

highlight_atomsdata

Optional atom indices to highlight

Output Ports

imagesimage

2D structure images

grid_imageimage

Grid of multiple structures

svg_datastring

SVG representation

Properties

PropertyTypeDefaultDescription
img_sizetuple(300, 300)Image dimensions (width, height)
mol_per_rowint3Molecules per row in grid
show_atom_numbersboolfalseDisplay atom indices
highlight_colorstringyellowHighlight color
kekulizebooltrueUse Kekulé form

ProLIF Interaction

Protein-ligand interaction fingerprinting and analysis

Type: prolif_interactionCategory: Molecular Visualization

Key Features

  • Hydrogen bonds detection
  • Hydrophobic interactions
  • π-π stacking analysis
  • Salt bridges identification
  • Interactive visualizations

Input Ports

protein_moleculesmolecules

Protein structure

ligand_moleculesmolecules

Ligand molecules

trajectory_filefile

Optional MD trajectory

Output Ports

interaction_datadata

Interaction fingerprint DataFrame

interaction_plotimage

Interaction heatmap

network_plotimage

Interaction network diagram

barcode_plotimage

Interaction barcode

Properties

PropertyTypeDefaultDescription
interactionsstringallInteraction types to detect
distance_cutofffloat4.5Distance cutoff (Å)
residue_selectionstringallResidues to analyze
plot_typestringheatmapVisualization type

Web 3D Viewer

Interactive 3D molecular viewer using NGL.js

Type: web3d_viewerCategory: Molecular Visualization

Key Features

  • Interactive 3D rotation/zoom
  • Multiple representation styles
  • Trajectory playback
  • Measurement tools
  • Export as HTML

Input Ports

moleculesmolecules

Molecular structures

trajectory_filefile

Optional trajectory

structure_filefile

Or structure file (PDB/SDF)

Output Ports

viewer_htmlfile

Standalone HTML viewer

viewer_urlstring

Viewer URL

screenshotimage

Static screenshot

Properties

PropertyTypeDefaultDescription
representationstringcartoonDisplay style (cartoon, ball+stick, surface)
color_schemestringchainidColoring (element, chain, residue)
backgroundstringwhiteBackground color
show_axesboolfalseShow orientation axes
auto_viewbooltrueAuto-center view

Histogram Plot

Create histogram distributions with statistical overlays

Type: plot_histogramCategory: Statistical Plots

Key Features

  • Automatic bin optimization
  • KDE overlay option
  • Statistical annotations
  • Multiple histograms
  • Interactive plotly output

Input Ports

datadata

Data values (DataFrame or array)

column_namestring

Optional column to plot

Output Ports

plotimage

Histogram plot

statisticsdata

Distribution statistics

bins_datadata

Bin edges and counts

Properties

PropertyTypeDefaultDescription
binsintautoNumber of bins
densityboolfalseNormalize to density
cumulativeboolfalseCumulative histogram
overlaystringnoneOverlay (kde, normal)
colorstringblueBar color

Scatter Plot

2D/3D scatter plots with regression lines

Type: plot_scatterCategory: Statistical Plots

Key Features

  • 2D and 3D scatter plots
  • Color/size mapping
  • Regression lines
  • Confidence intervals
  • Interactive hover data

Input Ports

datadata

DataFrame with x, y columns

x_datadata

Or separate x values

y_datadata

And y values

z_datadata

Optional z for 3D

Output Ports

plotimage

Scatter plot

regression_statsdata

Regression statistics

correlationdata

Correlation coefficient

Properties

PropertyTypeDefaultDescription
x_columnstringX axis column
y_columnstringY axis column
color_columnstringColor by column
size_columnstringSize by column
trendlinestringnoneTrendline type (linear, lowess)
marker_sizeint8Marker size

Line Plot

Time series and line charts with multiple traces

Type: plot_lineCategory: Statistical Plots

Key Features

  • Multiple traces
  • Time series support
  • Area fills
  • Smooth interpolation
  • Dual y-axes

Input Ports

datadata

DataFrame or arrays

x_datadata

X axis values

y_datadata

Y axis values

Output Ports

plotimage

Line plot

plot_datadata

Plot data export

Properties

PropertyTypeDefaultDescription
x_columnstringX axis column
y_columnsstringY columns (comma-separated)
line_stylestringsolidLine style
markersboolfalseShow markers
fillstringnoneFill area (tozeroy, tonexty)

Bar Plot

Bar charts with grouping and stacking

Type: plot_barCategory: Statistical Plots

Key Features

  • Grouped bars
  • Stacked bars
  • Horizontal/vertical
  • Error bars
  • Annotations

Input Ports

datadata

DataFrame with categories and values

categoriesdata

Category labels

valuesdata

Bar heights

Output Ports

plotimage

Bar plot

summary_statsdata

Summary statistics

Properties

PropertyTypeDefaultDescription
orientationstringverticalBar orientation
bar_modestringgroupMode (group, stack, overlay)
color_discrete_mapstringColor mapping
show_valuesbooltrueShow value labels

Heatmap Plot

2D heatmaps with hierarchical clustering

Type: plot_heatmapCategory: Statistical Plots

Key Features

  • Hierarchical clustering
  • Custom color scales
  • Dendrograms
  • Cell annotations
  • Interactive zoom

Input Ports

datadata

2D matrix or DataFrame

row_labelsdata

Optional row labels

col_labelsdata

Optional column labels

Output Ports

plotimage

Heatmap plot

clustered_datadata

Clustered matrix

dendrogramimage

Optional dendrogram

Properties

PropertyTypeDefaultDescription
colorscalestringviridisColor scale
cluster_rowsboolfalseCluster rows
cluster_colsboolfalseCluster columns
show_scalebooltrueShow color scale
annotateboolfalseShow cell values

Pie/Donut Plot

Pie and donut charts for proportional data

Type: plot_pieCategory: Statistical Plots

Key Features

  • Pie and donut styles
  • Percentage labels
  • Exploded slices
  • Custom colors
  • Interactive legends

Input Ports

datadata

Categories and values

labelsdata

Category labels

valuesdata

Category values

Output Ports

plotimage

Pie/donut chart

percentagesdata

Percentage breakdown

Properties

PropertyTypeDefaultDescription
holefloat0Hole size (0 for pie, >0 for donut)
textpositionstringautoLabel position
textinfostringpercent+labelText display
pullfloat0Explode slices

Box Plot

Box plots showing quartiles and outliers

Type: plot_boxCategory: Statistical Plots

Key Features

  • Quartile visualization
  • Outlier detection
  • Group comparisons
  • Mean overlay
  • Confidence intervals

Input Ports

datadata

Data values or DataFrame

groupsdata

Optional grouping variable

Output Ports

plotimage

Box plot

statisticsdata

Quartile statistics

outliersdata

Outlier points

Properties

PropertyTypeDefaultDescription
orientationstringverticalPlot orientation
notchedboolfalseShow confidence notch
show_meanboolfalseShow mean line
pointsstringoutliersPoint display (all, outliers, none)

Violin Plot

Violin plots combining KDE and box plots

Type: plot_violinCategory: Statistical Plots

Key Features

  • Distribution shape
  • Embedded box plot
  • KDE smoothing
  • Split violins
  • Statistical overlays

Input Ports

datadata

Data values

groupsdata

Grouping variable

Output Ports

plotimage

Violin plot

kde_datadata

KDE curves

statisticsdata

Distribution stats

Properties

PropertyTypeDefaultDescription
box_visiblebooltrueShow box plot inside
meanline_visibleboolfalseShow mean line
pointsstringnoneShow data points
bandwidthfloatautoKDE bandwidth

Volcano Plot

Volcano plots for differential expression analysis

Type: plot_volcanoCategory: Scientific Plots

Key Features

  • Significance thresholds
  • Auto-labeling
  • Color by significance
  • Interactive tooltips
  • Export significant list

Input Ports

datadata

DataFrame with fold change and p-values

fold_changedata

Or separate fold change

pvaluesdata

And p-values

Output Ports

plotimage

Volcano plot

significant_genesdata

Significant features

statisticsdata

Statistical summary

Properties

PropertyTypeDefaultDescription
fc_thresholdfloat2.0Fold change cutoff
pvalue_thresholdfloat0.05P-value cutoff
log_transformbooltrueLog transform FC
label_topint10Label top N points

Venn Diagram

Venn diagrams for set intersections (2-3 sets)

Type: plot_vennCategory: Scientific Plots

Key Features

  • 2 and 3 set diagrams
  • Proportional sizing
  • Intersection counts
  • Custom colors
  • Export intersections

Input Ports

set1data

First set of items

set2data

Second set

set3data

Optional third set

Output Ports

plotimage

Venn diagram

intersectionsdata

Intersection counts

unique_itemsdata

Unique items per region

Properties

PropertyTypeDefaultDescription
set_labelsstringSet1,Set2,Set3Set names
colorsstringred,blue,greenSet colors
alphafloat0.4Transparency
show_percentagesboolfalseShow percentages

Pair Plot

Matrix of scatter plots for multi-dimensional data

Type: plot_pairplotCategory: Scientific Plots

Key Features

  • All pairwise relationships
  • Diagonal distributions
  • Group coloring
  • Regression lines
  • Correlation annotations

Input Ports

datadata

Multi-column DataFrame

hue_columnstring

Optional grouping column

Output Ports

plotimage

Pair plot matrix

correlationsdata

Correlation matrix

regression_statsdata

Pairwise regressions

Properties

PropertyTypeDefaultDescription
diag_kindstringhistDiagonal plot type (hist, kde)
plot_kindstringscatterOff-diagonal plots (scatter, reg)
heightfloat2.5Subplot height
cornerboolfalseShow lower triangle only

Radar Plot

Radar/spider charts for multivariate comparison

Type: plot_radarCategory: Scientific Plots

Key Features

  • Multi-dimensional comparison
  • Multiple traces
  • Area filling
  • Custom scaling
  • Interactive legends

Input Ports

datadata

DataFrame with variables

categoriesdata

Variable names

valuesdata

Variable values

Output Ports

plotimage

Radar chart

normalized_datadata

Normalized values

Properties

PropertyTypeDefaultDescription
fillbooltrueFill area
normalizebooltrueNormalize to 0-1
show_gridbooltrueShow grid lines
line_widthint2Line thickness

Visualization Best Practices

  • Choose the right plot type: Use histograms for distributions, scatter for correlations, line for time series, and heatmaps for matrices.
  • Interactive vs Static: Plotly outputs are interactive and great for exploration, while static images are better for publications.
  • Molecular visualization: Use 2D for structure comparison, 3D viewer for spatial analysis, and ProLIF for interaction studies.
  • Publication quality: Adjust DPI, font sizes, and color schemes for journal requirements. Export as vector graphics when possible.