xPolarDot | R Documentation

## Function to visualise a data frame using a polar dotplot

### Description

`xPolarDot` is supposed to visualise a data frame using a polar dotplot. It returns an object of class "ggplot".

### Usage

    xPolarDot(df, colormap = "blue-yellow-red", shape = 19, size = 2,
    parallel = FALSE, font.family = "sans", signature = TRUE)

### Arguments

`df` | a data frame with two columns ('name' and 'value')
`colormap` | either NULL or color names ('blue-yellow-red' by default) for points according to the value column
`shape` | an integer specifying point shape
`size` | an integer specifying the point size. By default, it sets to 2
`parallel` | logical to indicate whether the label is parallel to polar coordinate. By default, it sets FALSE
`font.family` | the font family for texts
`signature` | logical to indicate whether the signature is assigned to the plot caption. By default, it sets TRUE showing which function is used to draw this graph

### Value

an object of class "ggplot"

### Note

none

### See Also

`xPolarDot`

### Examples

    # Load the XGR package and specify the location of built-in data
    library(XGR)
    RData.location <- "http://galahad.well.ox.ac.uk/bigdata/"

    ## Not run:
    # a) provide the seed nodes/genes with the weight info
    ## load ImmunoBase
    ImmunoBase <- xRDataLoader(RData.customised='ImmunoBase',
    RData.location=RData.location)
    ## get genes within 500kb away from AS GWAS lead SNPs
    seeds.genes <- ImmunoBase$AS$genes_variants
    ## seeds weighted according to distance away from lead SNPs
    data <- 1- seeds.genes/500000

    # b) prepare a data frame
    df <- data.frame(name=names(data), value=data, stringsAsFactors=FALSE)

    # c) do correlation
    gp <- xPolarDot(df[1:50,])
    gp

    ## End(Not run)