CellexalVR  1.1.0
A virtual reality platform for the exploration and analysis of single-cell gene expression data
CellexalVR.AnalysisObjects.GraphGenerator Class Reference

A graph that contain one or more CombinedCluster that in turn contain one or more CombinedGraphPoint. More...

Inheritance diagram for CellexalVR.AnalysisObjects.GraphGenerator:

Classes

struct  CombineMeshesJob
 Job that combines the meshes of one cluster. More...
 

Public Types

enum  GraphType {
  MDS, FACS, ATTRIBUTE, BETWEEN,
  SPATIAL
}
 

Public Member Functions

Graph CreateGraph (GraphType type)
 Creates a new graph of the given type. More...
 
void CreateShaderColors ()
 Creates the texture that the CombinedGraph shader uses to fetch colors for the graphpoints. More...
 
Graph.GraphPoint AddGraphPoint (Cell cell, float x, float y, float z, Graph graph=null)
 Adds a graphpoint to this graph. The coordinates should be scaled later with ScaleAllCoordinates. More...
 
void AddAxes (Graph graph, string[] axisNames)
 Adds arrows representing the axes of the graph. More...
 
void AddLODGroup (Graph combGraph, int i)
 Helper function to add level of detail group when building graphs. More...
 
IEnumerator SliceClusteringLOD (int lodGroups, Dictionary< string, Graph.GraphPoint > points=null, GraphSlice slice=null)
 Coroutine. Divides the graph into clusters and creates one mesh for each cluster per LOD group. More...
 
List< HashSet< Graph.GraphPoint > > SliceClustering (Dictionary< string, Graph.GraphPoint > points=null, GraphSlice slice=null)
 Divides the graph into clusters. The graph starts out as one large cluster and is recursively divided into smaller and smaller clusters until all clusters can be rendered in Unity using a single mesh. More...
 
void UpdateCoords ()
 
void CreateSubGraphs ()
 
void CreateMeshFromCommandLine ()
 
void CreateMesh ()
 
void CreateSubGraphs (List< string > attributes)
 Creates a subgraph based on some attrbiutes. More...
 
void UpdateMeshToUse ()
 
IEnumerator RebuildGraphs ()
 Rebuilding graphs while when mesh has changed such as to another size or quality. The color of the points are kept More...
 
void UpdateLODGroups (Graph graph=null, int nrOfLODGroups=1, GraphSlice slice=null)
 Updates the LODGroup components list of renderers. More...
 

Static Public Member Functions

static string V2S (Vector2 v)
 
static string V2S (Vector3 v)
 
static string V2S (Vector4 v)
 

Public Attributes

ReferenceManager referenceManager
 
GameObject graphpointsPrefab
 
GameObject graphPrefab
 
GameObject spatialSlicePrefab
 
GameObject AxesPrefabColoured
 
GameObject AxesPrefabUncoloured
 
Material graphPointMaterialPrefab
 
GameObject skeletonPrefab
 
Mesh graphpointStandardQStandardSzMesh
 
Mesh graphpointStandardQSmallSzMesh
 
Mesh graphpointStandardQLargeSzMesh
 
Mesh graphpointLowQStandardSzMesh
 
Mesh graphpointLowQSmallSzMesh
 
Mesh graphpointLowQLargeSzMesh
 
Mesh meshToUse
 
bool isCreating
 
int nrOfLODGroups = 3
 
Color[] geneExpressionColors
 
Texture2D graphPointColors
 
int graphCount
 
Graph newGraph
 

Properties

string DirectoryName [get, set]
 

Detailed Description

A graph that contain one or more CombinedCluster that in turn contain one or more CombinedGraphPoint.

Member Function Documentation

◆ AddAxes()

void CellexalVR.AnalysisObjects.GraphGenerator.AddAxes ( Graph  graph,
string[]  axisNames 
)

Adds arrows representing the axes of the graph.

Parameters
graphThe graph to add axes to.
axisNamesThe labels on the axes.

◆ AddGraphPoint()

Graph.GraphPoint CellexalVR.AnalysisObjects.GraphGenerator.AddGraphPoint ( Cell  cell,
float  x,
float  y,
float  z,
Graph  graph = null 
)

Adds a graphpoint to this graph. The coordinates should be scaled later with ScaleAllCoordinates.

Parameters
labelThe graphpoint's (cell's) name.
xThe x-coordinate.
yThe y-coordinate.
zThe z-coordinate.

◆ AddLODGroup()

void CellexalVR.AnalysisObjects.GraphGenerator.AddLODGroup ( Graph  combGraph,
int  i 
)

Helper function to add level of detail group when building graphs.

◆ CreateGraph()

Graph CellexalVR.AnalysisObjects.GraphGenerator.CreateGraph ( GraphType  type)

Creates a new graph of the given type.

Parameters
typeThe type of graph to create.
Returns
The new graph.

◆ CreateShaderColors()

void CellexalVR.AnalysisObjects.GraphGenerator.CreateShaderColors ( )

Creates the texture that the CombinedGraph shader uses to fetch colors for the graphpoints.

◆ CreateSubGraphs()

void CellexalVR.AnalysisObjects.GraphGenerator.CreateSubGraphs ( List< string >  attributes)

Creates a subgraph based on some attrbiutes.

Parameters
attributesThe attributes to include in the subgraph.

◆ RebuildGraphs()

IEnumerator CellexalVR.AnalysisObjects.GraphGenerator.RebuildGraphs ( )

Rebuilding graphs while when mesh has changed such as to another size or quality. The color of the points are kept

Returns

◆ SliceClustering()

List<HashSet<Graph.GraphPoint> > CellexalVR.AnalysisObjects.GraphGenerator.SliceClustering ( Dictionary< string, Graph.GraphPoint points = null,
GraphSlice  slice = null 
)

Divides the graph into clusters. The graph starts out as one large cluster and is recursively divided into smaller and smaller clusters until all clusters can be rendered in Unity using a single mesh.

◆ SliceClusteringLOD()

IEnumerator CellexalVR.AnalysisObjects.GraphGenerator.SliceClusteringLOD ( int  lodGroups,
Dictionary< string, Graph.GraphPoint points = null,
GraphSlice  slice = null 
)

Coroutine. Divides the graph into clusters and creates one mesh for each cluster per LOD group.

Parameters
lodGroupsThe number of LOD groups to create.
pointsOptional. The points to cluster, or null for all graph points in the currently creating graph.

◆ UpdateLODGroups()

void CellexalVR.AnalysisObjects.GraphGenerator.UpdateLODGroups ( Graph  graph = null,
int  nrOfLODGroups = 1,
GraphSlice  slice = null 
)

Updates the LODGroup components list of renderers.

Parameters
graphThe graph to update LODGroup for.
nrOfLODGroupsThe numnber of LOD groups.
sliceUse if updating a GraphSlice instead of a Graph.

The documentation for this class was generated from the following file: