You can also read/write portions of the text till you get to the line
you want to change, change it and then continue copying the lines.
This is what would be done with any other software approach in trying
to replace 'text' that may not be the same length.

On Fri, Apr 17, 2009 at 4:20 AM, Guillaume Filteau <filt...@unc.edu> wrote:
> Hello all,
>
> Is it possible to modify a single line in a textfile?
>
> I know it is possible to load the whole text file, do the change, and  save
> this as a new file. However, this is not practical in my case, because the
> document is huge and cannot be fully loaded in R.
>
> Any idea?
> Best,
> Guillaume
>
> ______________________________________________
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>



-- 
Jim Holtman
Cincinnati, OH
+1 513 646 9390

What is the problem that you are trying to solve?

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to