[Bioc-devel] How can I remove limit of row numbers that can be printed on console?

Arman Shahrisa shahrisa.arman at hotmail.com
Fri Sep 8 22:01:37 CEST 2017


Thank you for asking. It is a matrix. The following is a sample from cgdsr package and
how it can be useful. The users then choose the desired studies from the list. It uses
the printing approach. I can’t store out put of my function as a variable (assgn()) as
specified by my reviewer. when R truncates the output, it is incomplete. User has to
run the code once more and try to manually assign it to a new variable by arrow sign.
Some users even don’t get it after running the code twice.

Regards,
Arman


library(cgdsr)
mycgds = CGDS("http://www.cbioportal.org/")
getCancerStudies(mycgds)[,c(1,2)]

                     cancer_study_id
1                      paac_jhu_2014
2                      laml_tcga_pub
3                          laml_tcga
4                      acyc_fmi_2014
5                      acyc_mda_2015
6                    acyc_mskcc_2013
7                   acyc_sanger_2013
8                    acbc_mskcc_2015
9                           acc_tcga
10                    ampca_bcm_2016
11             blca_mskcc_solit_2014
12             blca_mskcc_solit_2012
13      blca_plasmacytoid_mskcc_2016
14                          blca_bgi
15           blca_dfarber_mskcc_2014
16                     blca_tcga_pub
17                         blca_tcga
18                          lgg_tcga
19                     brca_metabric
20                        brca_bccrc
21                        brca_broad
22                       brca_sanger
23                 brca_tcga_pub2015
24                     brca_tcga_pub
25                         brca_tcga
26         brca_bccrc_xenograft_2014
27               cellline_ccle_broad
28                         cesc_tcga
29                    chol_nccs_2013
30                     chol_nus_2012
31                         chol_tcga
32                   lcll_broad_2013
33                    cll_iuopa_2015
34                 ccrcc_utokyo_2013
35                coadread_dfci_2016
36                coadread_genentech
37                 coadread_tcga_pub
38                     coadread_tcga
39                    coadread_mskcc
40                ctcl_columbia_2015
41                 cscc_dfarber_2015
42                     pact_jhu_2011
43                   desm_broad_2015
44                   dlbc_broad_2012
45                        esca_broad
46                         esca_tcga
47                         escc_icgc
48                    escc_ucla_2014
49                   es_iocurie_2014
50                 gbc_shanghai_2014
51                   egc_tmucih_2015
52                  nsclc_unito_2016
53                    skcm_ucla_2016
54                    prad_cpcg_2017
55                      gct_msk_2016
56                  gbm_tcga_pub2013
57                      gbm_tcga_pub
58                          gbm_tcga
59                        hnsc_broad
60                          hnsc_jhu
61                     hnsc_tcga_pub
62                         hnsc_tcga
63               liad_inserm_fr_2014
64                hcc_inserm_fr_2015
65                   all_stjude_2013
66                   all_stjude_2015
67               panet_shanghai_2013
68               mel_tsam_liang_2017
69                     chol_jhu_2013
70                     kich_tcga_pub
71                         kich_tcga
72                          kirc_bgi
73                     kirc_tcga_pub
74                         kirc_tcga
75                         kirp_tcga
76                      lihc_amc_prv
77                        lihc_riken
78                         lihc_tcga
79                     lgg_ucsf_2014
80                        luad_broad
81                   luad_mskcc_2015
82                     luad_tcga_pub
83                         luad_tcga
84                          luad_tsp
85                     lusc_tcga_pub
86                         lusc_tcga
87                         dlbc_tcga
88                   prad_mskcc_2017
89                   msk_impact_2017
90                       mpnst_mskcc
91                   plmeso_nyu_2015
92                  mcl_idibips_2013
93                    mbl_broad_2012
94                          mbl_icgc
95                          mbl_pcgp
96                 mbl_sickkids_2016
97                skcm_broad_dfarber
98                   lgggbm_tcga_pub
99                         meso_tcga
100                   prad_su2c_2015
101                         mm_broad
102                   ccrcc_irc_2014
103                    brca_igr_2015
104                   mds_tokyo_2011
105                   cellline_nci60
106                     odg_msk_2017
107                  npc_nusingapore
108                     nbl_amc_2012
109                nbl_ucologne_2015
110                    nepc_wcm_2016
111             hnsc_mdanderson_2013
112                      ov_tcga_pub
113                          ov_tcga
114       skcm_vanderbilt_mskcc_2015
115            nsclc_tcga_broad_2016
116                        paad_icgc
117                paad_qcmg_uq_2016
118                        paad_tcga
119                   paad_utsw_2015
120                   panet_jhu_2011
121                    thca_tcga_pub
122            es_dfarber_broad_2014
123                        pcpg_tcga
124               thyroid_mskcc_2016
125                  pcnsl_mayo_2015
126                  prad_broad_2013
127                       prad_broad
128                       prad_fhcrc
129                       prad_mskcc
130                    prad_tcga_pub
131                        prad_tcga
132                  prad_mskcc_2014
133 prad_mskcc_cheny1_organoids_2014
134                        prad_mich
135                   hnc_mskcc_2016
136            nccrcc_genentech_2014
137                     rms_nih_2014
138                       sarc_mskcc
139                        sarc_tcga
140                       skcm_broad
141                        skcm_tcga
142                        skcm_yale
143                       scco_mskcc
144                       sclc_clcgp
145                         sclc_jhu
146               sclc_ucologne_2015
147            stad_pfizer_uhongkong
148                    stad_tcga_pub
149                        stad_tcga
150                      stad_utokyo
151                   stad_uhongkong
152                    stes_tcga_pub
153                        tgct_tcga
154                     tet_nci_2014
155                        thym_tcga
156                        thca_tcga
157                  urcc_mskcc_2016
158                     ucs_jhu_2014
159                         ucs_tcga
160                    ucec_tcga_pub
161                        ucec_tcga
162                         uvm_tcga
163                panet_arcnet_2017
164        past_dkfz_heidelberg_2013
                                                                                                                                                  name
1                                                                                 Acinar Cell Carcinoma of the Pancreas (Johns Hopkins, J Pathol 2014)
2                                                                                                             Acute Myeloid Leukemia (TCGA, NEJM 2013)
3                                                                                                           Acute Myeloid Leukemia (TCGA, Provisional)
4                                                                                                Adenoid Cystic Carcinoma (FMI, Am J Surg Pathl. 2014)
5                                                                                                 Adenoid Cystic Carcinoma (MDA, Clin Cancer Res 2015)
6                                                                                                     Adenoid Cystic Carcinoma (MSKCC, Nat Genet 2013)
7                                                                                                      Adenoid Cystic Carcinoma (Sanger/MDA, JCI 2013)
8                                                                                       Adenoid Cystic Carcinoma of the Breast (MSKCC, J Pathol. 2015)
9                                                                                                         Adrenocortical Carcinoma (TCGA, Provisional)
10                                                                                 Ampullary Carcinoma (Baylor College of Medicine, Cell Reports 2016)
11                                                                                                               Bladder Cancer (MSKCC, Eur Urol 2014)
12                                                                                                                    Bladder Cancer (MSKCC, JCO 2013)
13                                                                                        Bladder Cancer, Plasmacytoid Variant (MSKCC, Nat Genet 2016)
14                                                                                                  Bladder Urothelial Carcinoma (BGI, Nat Genet 2013)
15                                                                              Bladder Urothelial Carcinoma (Dana Farber & MSKCC, Cancer Discov 2014)
16                                                                                                    Bladder Urothelial Carcinoma (TCGA, Nature 2014)
17                                                                                                    Bladder Urothelial Carcinoma (TCGA, Provisional)
18                                                                                                        Brain Lower Grade Glioma (TCGA, Provisional)
19                                                                                             Breast Cancer (METABRIC, Nature 2012 & Nat Commun 2016)
20                                                                                           Breast Invasive Carcinoma (British Columbia, Nature 2012)
21                                                                                                      Breast Invasive Carcinoma (Broad, Nature 2012)
22                                                                                                     Breast Invasive Carcinoma (Sanger, Nature 2012)
23                                                                                                         Breast Invasive Carcinoma (TCGA, Cell 2015)
24                                                                                                       Breast Invasive Carcinoma (TCGA, Nature 2012)
25                                                                                                       Breast Invasive Carcinoma (TCGA, Provisional)
26                                                                                    Breast cancer patient xenografts (British Columbia, Nature 2014)
27                                                                                         Cancer Cell Line Encyclopedia (Novartis/Broad, Nature 2012)
28                                                                Cervical Squamous Cell Carcinoma and Endocervical Adenocarcinoma (TCGA, Provisional)
29                                                                            Cholangiocarcinoma (National Cancer Centre of Singapore, Nat Genet 2013)
30                                                                               Cholangiocarcinoma (National University of Singapore, Nat Genet 2012)
31                                                                                                              Cholangiocarcinoma (TCGA, Provisional)
32                                                                                                     Chronic Lymphocytic Leukemia (Broad, Cell 2013)
33                                                                                                   Chronic Lymphocytic Leukemia (IUOPA, Nature 2015)
34                                                                                           Clear Cell Renal Cell Carcinoma (U Tokyo, Nat Genet 2013)
35                                                                                                 Colorectal Adenocarcinoma (DFCI, Cell Reports 2016)
36                                                                                                  Colorectal Adenocarcinoma (Genentech, Nature 2012)
37                                                                                                       Colorectal Adenocarcinoma (TCGA, Nature 2012)
38                                                                                                       Colorectal Adenocarcinoma (TCGA, Provisional)
39                                                                                        Colorectal Adenocarcinoma Triplets (MSKCC, Genome Biol 2014)
40                                                                                              Cutaneous T Cell Lymphoma (Columbia U, Nat Genet 2015)
41                                                                                      Cutaneous squamous cell carcinoma (DFCI, Clin Cancer Res 2015)
42                                                                                              Cystic Tumor of the Pancreas (Johns Hopkins, PNAS 2011
43                                                                                             Desmoplastic Melanoma (Broad Institute, Nat Genet 2015)
44                                                                                                    Diffuse Large B-Cell Lymphoma (Broad, PNAS 2012)
45                                                                                                   Esophageal Adenocarcinoma (Broad, Nat Genet 2013)
46                                                                                                            Esophageal Carcinoma (TCGA, Provisional)
47                                                                                              Esophageal Squamous Cell Carcinoma (ICGC, Nature 2014)
48                                                                                           Esophageal Squamous Cell Carcinoma (UCLA, Nat Genet 2014)
49                                                                                                  Ewing Sarcoma (Institut Cuire, Cancer Discov 2014)
50                                                                                                    Gallbladder Carcinoma (Shanghai, Nat Genet 2014)
51                                                                                                          Gastric Adenocarcinoma (TMUCIH, PNAS 2015)
52                                                     Genetic Characterization of NSCLC young adult patients ( University of Turin, Lung Cancer 2016)
53                                                                          Genetic Characterization of pretreatment melanoma tumors (UCLA, Cell 2016)
54                                                                                Genomic Hallmarks of Prostate Adenocarcinoma (CPC-GENE, Nature 2017)
55                                                                         Genomic Profile of Patients with Advanced Germ Cell Tumors (MSK, JCO 2016).
56                                                                                                                      Glioblastoma (TCGA, Cell 2013)
57                                                                                                                    Glioblastoma (TCGA, Nature 2008)
58                                                                                                         Glioblastoma Multiforme (TCGA, Provisional)
59                                                                                         Head and Neck Squamous Cell Carcinoma (Broad, Science 2011)
60                                                                                 Head and Neck Squamous Cell Carcinoma (Johns Hopkins, Science 2011)
61                                                                                           Head and Neck Squamous Cell Carcinoma (TCGA, Nature 2015)
62                                                                                           Head and Neck Squamous Cell Carcinoma (TCGA, Provisional)
63                                                                                                   Hepatocellular Adenoma (Inserm, Cancer Cell 2014)
64                                                                                                  Hepatocellular Carcinomas (Inserm, Nat Genet 2015)
65                                                                                       Hypodiploid Acute Lymphoid Leukemia (St Jude, Nat Genet 2013)
66                                                                        Infant MLL-Rearranged Acute Lymphoblastic Leukemia (St Jude, Nat Genet 2015)
67                                                                                                              Insulinoma (Shanghai, Nat Commun 2013)
68                                                   Integrated genomic analyses reveal frequent TERT aberrations in acral melanoma. (Genome Res 2017)
69                                                                          Intrahepatic Cholangiocarcinoma (Johns Hopkins University, Nat Genet 2013)
70                                                                                                         Kidney Chromophobe (TCGA, Cancer Cell 2014)
71                                                                                                              Kidney Chromophobe (TCGA, Provisional)
72                                                                                             Kidney Renal Clear Cell Carcinoma (BGI, Nat Genet 2012)
73                                                                                               Kidney Renal Clear Cell Carcinoma (TCGA, Nature 2013)
74                                                                                               Kidney Renal Clear Cell Carcinoma (TCGA, Provisional)
75                                                                                           Kidney Renal Papillary Cell Carcinoma (TCGA, Provisional)
76                                                                                               Liver Hepatocellular Carcinoma (AMC, Hepatology 2014)
77                                                                                              Liver Hepatocellular Carcinoma (RIKEN, Nat Genet 2012)
78                                                                                                  Liver Hepatocellular Carcinoma (TCGA, Provisional)
79                                                                                                              Low-Grade Gliomas (UCSF, Science 2014)
80                                                                                                              Lung Adenocarcinoma (Broad, Cell 2012)
81                                                                                                                    Lung Adenocarcinoma (MSKCC 2015)
82                                                                                                             Lung Adenocarcinoma (TCGA, Nature 2014)
83                                                                                                             Lung Adenocarcinoma (TCGA, Provisional)
84                                                                                                              Lung Adenocarcinoma (TSP, Nature 2008)
85                                                                                                    Lung Squamous Cell Carcinoma (TCGA, Nature 2012)
86                                                                                                    Lung Squamous Cell Carcinoma (TCGA, Provisional)
87                                                                                 Lymphoid Neoplasm Diffuse Large B-cell Lymphoma (TCGA, Provisional)
88                                                                                      MSK-IMPACT Clinical Sequencing Cohort (MSKCC): Prostate Cancer
89                                                                                         MSK-IMPACT Clinical Sequencing Cohort (MSKCC, Nat Med 2017)
90                                                                                     Malignant Peripheral Nerve Sheath Tumor (MSKCC, Nat Genet 2014)
91                                                                                               Malignant Pleural Mesothelioma (NYU, Cancer Res 2015)
92                                                                                                           Mantle Cell Lymphoma (IDIBIPS, PNAS 2013)
93                                                                                                                Medulloblastoma (Broad, Nature 2012)
94                                                                                                                 Medulloblastoma (ICGC, Nature 2012)
95                                                                                                                 Medulloblastoma (PCGP, Nature 2012)
96                                                                                                             Medulloblastoma (Sickkids, Nature 2016)
97                                                                                                           Melanoma (Broad/Dana Farber, Nature 2012)
98                                                                                                      Merged Cohort of LGG and GBM (TCGA, Cell 2016)
99                                                                                                                    Mesothelioma (TCGA, Provisional)
100                                                                       Metastatic Prostate Cancer, SU2C/PCF Dream Team (Robinson et al., Cell 2015)
101                                                                                                         Multiple Myeloma (Broad, Cancer Cell 2014)
102                                                                   Multiregion Sequencing of Clear Cell Renal Cell Carcinoma (IRC, Nat Genet 2014).
103                                                                                     Mutational profiles of metastatic breast cancer (France, 2016)
104                                                                                                                Myelodysplasia (Tokyo, Nature 2011)
105                                                                                                          NCI-60 Cell Lines (NCI, Cancer Res. 2012)
106                                              NGS in Anaplastic Oligodendroglioma and Anaplastic Oligoastrocytomas tumors (MSKCC, Neuro Oncol 2017)
107                                                                                               Nasopharyngeal Carcinoma (Singapore, Nat Genet 2014)
108                                                                                                         Neuroblastoma (AMC Amsterdam, Nature 2012)
109                                                                                                              Neuroblastoma (Broad, Nat Genet 2013)
110                                                                                         Neuroendocrine Prostate Cancer (Trento/Cornell/Broad 2016)
111                                                                                     Oral Squamous Cell Carcinoma (MD Anderson, Cancer Discov 2013)
112                                                                                              Ovarian Serous Cystadenocarcinoma (TCGA, Nature 2011)
113                                                                                              Ovarian Serous Cystadenocarcinoma (TCGA, Provisional)
114 PTEN loss of function alterations are associated with intrinsic resistance to BRAF inhibitors in metastatic melanoma (JCO Precision Oncology,2017)
115                                                                                                             Pan-Lung Cancer (TCGA, Nat Genet 2016)
116                                                                                                      Pancreatic Adenocarcinoma (ICGC, Nature 2012)
117                                                                                                      Pancreatic Adenocarcinoma (QCMG, Nature 2016)
118                                                                                                      Pancreatic Adenocarcinoma (TCGA, Provisional)
119                                                                                                          Pancreatic Cancer (UTSW, Nat Commun 2015)
120                                                                          Pancreatic Neuroendocrine Tumors (Johns Hopkins University, Science 2011)
121                                                                                                      Papillary Thyroid Carcinoma (TCGA, Cell 2014)
122                                                                                                 Pediatric Ewing Sarcoma (DFCI, Cancer Discov 2014)
123                                                                                             Pheochromocytoma and Paraganglioma (TCGA, Provisional)
124                                                                             Poorly-Differentiated and Anaplastic Thyroid Cancers (MSKCC, JCI 2016)
125                                                                        Primary Central Nervous System Lymphoma (Mayo Clinic, Clin Cancer Res 2015)
126                                                                                                 Prostate Adenocarcinoma (Broad/Cornell, Cell 2013)
127                                                                                            Prostate Adenocarcinoma (Broad/Cornell, Nat Genet 2012)
128                                                                                        Prostate Adenocarcinoma (Fred Hutchinson CRC, Nat Med 2016)
129                                                                                                  Prostate Adenocarcinoma (MSKCC, Cancer Cell 2010)
130                                                                                                          Prostate Adenocarcinoma (TCGA, Cell 2015)
131                                                                                                        Prostate Adenocarcinoma (TCGA, Provisional)
132                                                                                               Prostate Adenocarcinoma CNA study (MSKCC, PNAS 2014)
133                                                                                               Prostate Adenocarcinoma Organoids (MSKCC, Cell 2014)
134                                                                                        Prostate Adenocarcinoma, Metastatic (Michigan, Nature 2012)
135                                                                                  Recurrent and Metastatic Head & Neck Cancer (JAMA Oncology, 2016)
136                                                                                         Renal Non-Clear Cell Carcinoma (Genentech, Nat Genet 2014)
137                                                                                                         Rhabdomyosarcoma (NIH, Cancer Discov 2014)
138                                                                                                              Sarcoma (MSKCC/Broad, Nat Genet 2010)
139                                                                                                                        Sarcoma (TCGA, Provisional)
140                                                                                                         Skin Cutaneous Melanoma (Broad, Cell 2012)
141                                                                                                        Skin Cutaneous Melanoma (TCGA, Provisional)
142                                                                                                     Skin Cutaneous Melanoma (Yale, Nat Genet 2012)
143                                                                                          Small Cell Carcinoma of the Ovary (MSKCC, Nat Genet 2014)
144                                                                                                     Small Cell Lung Cancer (CLCGP, Nat Genet 2012)
145                                                                                             Small Cell Lung Cancer (Johns Hopkins, Nat Genet 2012)
146                                                                                                    Small Cell Lung Cancer (U Cologne, Nature 2015)
147                                                                                            Stomach Adenocarcinoma (Pfizer and UHK, Nat Genet 2014)
148                                                                                                         Stomach Adenocarcinoma (TCGA, Nature 2014)
149                                                                                                         Stomach Adenocarcinoma (TCGA, Provisional)
150                                                                                                   Stomach Adenocarcinoma (U Tokyo, Nat Genet 2014)
151                                                                                                       Stomach Adenocarcinoma (UHK, Nat Genet 2011)
152                                                                                        TCGA data for Esophagus-Stomach Cancers (TCGA, Nature 2017)
153                                                                                                    Testicular Germ Cell Cancer (TCGA, Provisional)
154                                                                                                     Thymic Epithelial Tumors (NCI, Nat Genet 2014)
155                                                                                                                        Thymoma (TCGA, Provisional)
156                                                                                                              Thyroid Carcinoma (TCGA, Provisional)
157                                                                                                     Unclassified Renal Cell Carcinoma (MSKCC 2016)
158                                                                                 Uterine Carcinosarcoma (Johns Hopkins University, Nat Commun 2014)
159                                                                                                         Uterine Carcinosarcoma (TCGA, Provisional)
160                                                                                           Uterine Corpus Endometrial Carcinoma (TCGA, Nature 2013)
161                                                                                           Uterine Corpus Endometrial Carcinoma (TCGA, Provisional)
162                                                                                                                 Uveal Melanoma (TCGA, Provisional)
163                                                                         Whole-Genome Sequencing of Pancreatic Neuroendocrine Tumors (Nature, 2017)
164                                                                         Whole-genome sequencing of pilocytic astrocytomasatic (Nat Genetics, 2013)



From: Hervé Pagès<mailto:hpages at fredhutch.org>
Sent: Friday, September 8, 2017 23:50
To: Arman Shahrisa<mailto:shahrisa.arman at hotmail.com>; bioc-devel<mailto:bioc-devel at r-project.org>
Subject: Re: [Bioc-devel] How can I remove limit of row numbers that can be printed on console?

Hi Arman,

You're not saying what kind of object you're trying to print
but if it's a matrix or a data.frame then

   print(x, max=nrow(x))

I'm not sure your users are going to find useful that your
function displays more than 99999 lines on their screen though...

Note that this more a general R programming question than a
Bioconductor question so the R-help mailing list would be a better
place to ask.

Cheers,
H.

On 09/08/2017 11:11 AM, Arman Shahrisa wrote:
>
> Hi everyone,
>
> How can I prevent the R from truncating the printed result on console? I have to
> print the output on console and I can�t use options(max.print = 10000) in my
> function. What else I can do?
>
> Sincerely
> Arman
>
>
>        [[alternative HTML version deleted]]
>
>
>
> _______________________________________________
> Bioc-devel at r-project.org mailing list
> https://urldefense.proofpoint.com/v2/url?u=https-3A__stat.ethz.ch_mailman_listinfo_bioc-2Ddevel&d=DwICAg&c=eRAMFD45gAfqt84VtBcfhQ&r=BK7q3XeAvimeWdGbWY_wJYbW0WYiZvSXAJJKaaPhzWA&m=w88PaHysSQzv2G0LUNhUYW4mqm4djlLrJm98kNP_CU8&s=4-dc114la3DQ_bTzLktj6fsnuEMWEgsKB7sOFut_c7M&e=
>

--
Hervé Pagès

Program in Computational Biology
Division of Public Health Sciences
Fred Hutchinson Cancer Research Center
1100 Fairview Ave. N, M1-B514
P.O. Box 19024
Seattle, WA 98109-1024

E-mail: hpages at fredhutch.org
Phone:  (206) 667-5791
Fax:    (206) 667-1319


	[[alternative HTML version deleted]]



More information about the Bioc-devel mailing list