Giter VIP home page Giter VIP logo

gng's Introduction

gng

Build Status AppVeyor Build Status CRAN_Status_Badge Coverage Status

An implementation of the Growing Neural Gas algorithm in Rcpp.

Example

You can run gng as follows:

library(gng)
data(iris)
gng_fit <- gng(as.matrix(iris[,1:4]))

And visualise it as follows:

plot_gng(gng_fit, iris[,5], max_size = 0.05, max_size_legend = .15)

gng's People

Contributors

rcannood avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

gng's Issues

GNG graph do not visualize

I try to plot GNG graph:
data(iris)
iris2 <- as.matrix(iris[,1:4])
a <- gng(iris2, max_iter = 20000, epsilon_b = 0.05, epsilon_n = 0.001, age_max = 200, max_nodes = 30, lambda = 200, alpha = 0.5, beta = 0.99, assign_cluster = T, verbose = T, make_logs = F, cpp = T)
flowsomlike_plot(a, iris[,5], max.size = 0.075)
NULL

flowsomlike_plot(gng_fit = a, labels = iris[,5], max.size = 0.075)
NULL

How to vizualize it?

"gng" is not avaliable for R v 4.2.1

Hi,

I was installing a package which is dependent to "gnn".
Faced an issue of incompatibility of "gnn" release and my version of R.

Installing package into ‘/.../renv/library/R-4.2/x86_64-pc-linux-gnu’
(as ‘lib’ is unspecified)
ERROR: dependency ‘gng’ is not available for package ‘TInGa’
* removing ‘/.../renv/library/R-4.2/x86_64-pc-linux-gnu/TInGa’
Warning messages:
1: package ‘gng’ is not available for this version of R

Is there a chance to overcome this problem or recompile the gnn for R v4.2.1 ?
Thanks in advance.

Best,
Rüçhan.

> sessionInfo()
R version 4.2.1 (2022-06-23)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 22.04.1 LTS

Matrix products: default
BLAS:   /usr/lib/x86_64-linux-gnu/atlas/libblas.so.3.10.3
LAPACK: /usr/lib/x86_64-linux-gnu/atlas/liblapack.so.3.10.3

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8     LC_MONETARY=en_US.UTF-8   
 [6] LC_MESSAGES=en_US.UTF-8    LC_PAPER=en_US.UTF-8       LC_NAME=C                  LC_ADDRESS=C               LC_TELEPHONE=C            
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats4    stats     graphics  grDevices datasets  utils     methods   base     

other attached packages:
 [1] RColorBrewer_1.1-3          slingshot_2.5.2             TrajectoryUtils_1.4.0       princurve_2.1.6            
 [5] SingleCellExperiment_1.18.1 SummarizedExperiment_1.26.1 Biobase_2.56.0              GenomicRanges_1.48.0       
 [9] GenomeInfoDb_1.32.4         IRanges_2.30.1              S4Vectors_0.34.0            BiocGenerics_0.42.0        
[13] MatrixGenerics_1.8.1        matrixStats_0.62.0          sp_1.5-0                    SeuratObject_4.1.2         
[17] Seurat_4.2.0                qs_0.25.4                  

loaded via a namespace (and not attached):
  [1] utf8_1.2.2                reticulate_1.26           tidyselect_1.2.0          htmlwidgets_1.5.4         grid_4.2.1               
  [6] Rtsne_0.16                devtools_2.4.5            munsell_0.5.0             codetools_0.2-18          ica_1.0-3                
 [11] future_1.28.0             miniUI_0.1.1.1            withr_2.5.0               spatstat.random_2.2-0     colorspace_2.0-3         
 [16] progressr_0.11.0          knitr_1.40                rstudioapi_0.14           ROCR_1.0-11               ggsignif_0.6.3           
 [21] tensor_1.5                listenv_0.8.0             labeling_0.4.2            GenomeInfoDbData_1.2.8    polyclip_1.10-0          
 [26] farver_2.1.1              pheatmap_1.0.12           rprojroot_2.0.3           parallelly_1.32.1         vctrs_0.4.2              
 [31] generics_0.1.3            xfun_0.33                 dittoSeq_1.9.3            R6_2.5.1                  ggbeeswarm_0.6.0         
 [36] cachem_1.0.6              bitops_1.0-7              spatstat.utils_2.3-1      DelayedArray_0.22.0       assertthat_0.2.1         
 [41] promises_1.2.0.1          scales_1.2.1              rgeos_0.5-9               beeswarm_0.4.0            gtable_0.3.1             
 [46] globals_0.16.1            processx_3.7.0            goftest_1.2-3             rlang_1.0.6               GlobalOptions_0.1.2      
 [51] splines_4.2.1             rstatix_0.7.0             rgdal_1.5-32              lazyeval_0.2.2            spatstat.geom_2.4-0      
 [56] broom_1.0.1               yaml_2.3.5                reshape2_1.4.4            abind_1.4-5               backports_1.4.1          
 [61] httpuv_1.6.6              usethis_2.1.6             tools_4.2.1               ggplot2_3.3.6             ellipsis_0.3.2           
 [66] spatstat.core_2.4-4       sessioninfo_1.2.2         ggridges_0.5.4            Rcpp_1.0.9                plyr_1.8.7               
 [71] sparseMatrixStats_1.8.0   zlibbioc_1.42.0           purrr_0.3.5               RCurl_1.98-1.9            prettyunits_1.1.1        
 [76] ps_1.7.1                  ggpubr_0.4.0.999          rpart_4.1.16              deldir_1.0-6              pbapply_1.5-0            
 [81] viridis_0.6.2             urlchecker_1.0.1          cowplot_1.1.1             zoo_1.8-11                ggrepel_0.9.1            
 [86] cluster_2.1.4             fs_1.5.2                  here_1.0.1                magrittr_2.0.3            data.table_1.14.2        
 [91] scattermore_0.8           circlize_0.4.15           lmtest_0.9-40             RANN_2.6.1                fitdistrplus_1.1-8       
 [96] pkgload_1.3.0             stringfish_0.15.7         patchwork_1.1.2           mime_0.12                 evaluate_0.17            
[101] xtable_1.8-4              gridExtra_2.3             shape_1.4.6               compiler_4.2.1            tibble_3.1.8             
[106] colorway_0.2.0            crayon_1.5.2              KernSmooth_2.23-20        htmltools_0.5.3           mgcv_1.8-40              
[111] later_1.3.0               ggprism_1.0.3.9000        scCustomize_0.7.0         tidyr_1.2.1               RcppParallel_5.1.5       
[116] lubridate_1.8.0           DBI_1.1.3                 RApiSerialize_0.1.2       MASS_7.3-58.1             Matrix_1.5-1             
[121] car_3.1-0                 cli_3.4.1                 parallel_4.2.1            igraph_1.3.5              forcats_0.5.2            
[126] pkgconfig_2.0.3           plotly_4.10.0             spatstat.sparse_2.1-1     paletteer_1.4.1           vipor_0.4.5              
[131] XVector_0.36.0            snakecase_0.11.0          callr_3.7.2               stringr_1.4.1             digest_0.6.29            
[136] sctransform_0.3.5         RcppAnnoy_0.0.19          janitor_2.1.0             spatstat.data_2.2-0       rmarkdown_2.17           
[141] leiden_0.4.3              uwot_0.1.14               DelayedMatrixStats_1.18.1 curl_4.3.3                shiny_1.7.2              
[146] lifecycle_1.0.3           nlme_3.1-160              jsonlite_1.8.2            carData_3.0-5             viridisLite_0.4.1        
[151] fansi_1.0.3               pillar_1.8.1              lattice_0.20-45           pkgbuild_1.3.1            ggrastr_1.0.1            
[156] fastmap_1.1.0             httr_1.4.4                survival_3.4-0            remotes_2.4.2             glue_1.6.2               
[161] png_0.1-7                 profvis_0.3.7             stringi_1.7.8             rematch2_2.1.2            memoise_2.0.1            
[166] renv_0.16.0               dplyr_1.0.10              irlba_2.3.5.1             future.apply_1.9.1    

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.