Dave Armstrong
2006-Apr-11 00:06 UTC
[R] Changing character limit in deparse, as.character and toString
Dear R-help Listers, I am curious if there is some (hopefully easy) way to change the number of characters that can be converted to a single string via any of deparse, as.character or toString. It seems that the limit is 500 for all of these. I saw a previous post where Prof. Ripley suggested that it was a "trivial" change in the R internals to change as.character's limit from 60 to 500, but I was hoping for something that didn't involve me trying to alter the R internals. Thanks for your help, Dave. -- Dave Armstrong University of Maryland Dept of Government and Politics 3140 Tydings Hall College Park, MD 20742 Office: 2103L Cole Field House Phone: 301-405-9735 e-mail: darmstrong@gvpt.umd.edu web: www.davearmstrong-ps.com [[alternative HTML version deleted]]
Prof Brian Ripley
2006-Apr-11 07:11 UTC
[R] Changing character limit in deparse, as.character and toString
On Mon, 10 Apr 2006, Dave Armstrong wrote:> Dear R-help Listers, > > I am curious if there is some (hopefully easy) way to change the number of > characters that can be converted to a single string via any of deparse, > as.character or toString. It seems that the limit is 500 for all of > these.None of those functions convert 'characters' to a single string! What actually are you trying to convert? I guess the issue is the maximum line length in deparsing. You can almost always just paste multiple lines together, and this is done for formulae at several places in the R codebase.> I saw a previous post where Prof. Ripley suggested that it was a > "trivial" change in the R internals to change as.character's limit from 60 > to 500, but I was hoping for something that didn't involve me trying to > alter the R internals.Please show respect other people's copyright, and quote exactly with a reference or not at all. (I was unable to find what you are non-quoting, and don't even know if it is still relevant.)> Dave Armstrong > University of Maryland > Dept of Government and Politics> PLEASE do read the posting guide! http://www.R-project.org/posting-guide.html-- Brian D. Ripley, ripley at stats.ox.ac.uk Professor of Applied Statistics, http://www.stats.ox.ac.uk/~ripley/ University of Oxford, Tel: +44 1865 272861 (self) 1 South Parks Road, +44 1865 272866 (PA) Oxford OX1 3TG, UK Fax: +44 1865 272595