search for: petzel

Displaying 17 results from an estimated 17 matches for "petzel".

Did you mean: paetzel
2023 Jan 13
1
return value of {....}
...ot;, x, y); return 0; } $ gcc -Wall a.c $ ./a.out Starting... Done: x=2200, y=110 I don't like that syntax (e.g., commas between expressions instead of the usual semicolons after expressions). Perhaps John Chambers et all didn't either. -Bill On Fri, Jan 13, 2023 at 2:28 AM Valentin Petzel <valentin at petzel.at> wrote: > Hello Akshay, > > R is quite inspired by LISP, where this is a common thing. It is not in > fact that {...} returned something, rather any expression evalulates to > some value, and for a compound statement that is the last evaluated > expre...
2023 Jan 12
4
return value of {....}
...We are living in the 21st?century world, and the R-core team might,I suppose, have a definite reason for"returning" the last value. Any comments? > > Thanking you, > Yours sincerely, > AKSHAY M KULKARNI > > ---------------------------------------- > *From:* Valentin Petzel <valentin at petzel.at> > *Sent:* Monday, January 9, 2023 9:18 PM > *To:* akshay kulkarni <akshay_e4 at hotmail.com> > *Cc:* R help Mailing list <r-help at r-project.org> > *Subject:* Re: [R] return value of {....} > ? > Hello Akshai, > > I think you are c...
2023 Jan 09
3
return value of {....}
...urning the last, or any value, is redundant? We are living in the 21st century world, and the R-core team might,I suppose, have a definite reason for"returning" the last value. Any comments? Thanking you, Yours sincerely, AKSHAY M KULKARNI ________________________________ From: Valentin Petzel <valentin at petzel.at> Sent: Monday, January 9, 2023 9:18 PM To: akshay kulkarni <akshay_e4 at hotmail.com> Cc: R help Mailing list <r-help at r-project.org> Subject: Re: [R] return value of {....} Hello Akshai, I think you are confusing {...} with local({...}). This one will e...
2023 Jan 10
1
return value of {....}
...> z <- .Last.value/2 > z [1] 10.5 Yes, you could have used "y" ... -----Original Message----- From: R-help <r-help-bounces at r-project.org <mailto:r-help-bounces at r-project.org> > On Behalf Of akshay kulkarni Sent: Monday, January 9, 2023 12:06 PM To: Valentin Petzel <valentin at petzel.at <mailto:valentin at petzel.at> > Cc: R help Mailing list <r-help at r-project.org <mailto:r-help at r-project.org> > Subject: Re: [R] return value of {....} Dear Valentin, But why should {....} "return" a value? It...
2023 Jan 09
1
return value of {....}
...? We are living in the 21st century > world, and the R-core team might,I suppose, have a definite reason > for"returning" the last value. Any comments? > > Thanking you, > Yours sincerely, > AKSHAY M KULKARNI > > ________________________________ > From: Valentin Petzel <valentin at petzel.at> > Sent: Monday, January 9, 2023 9:18 PM > To: akshay kulkarni <akshay_e4 at hotmail.com> > Cc: R help Mailing list <r-help at r-project.org> > Subject: Re: [R] return value of {....} > > Hello Akshai, > > I think you are confusing {....
2023 Jan 15
3
return value of {....}
...variables in R. > x <- 0 > g <- function () { + n <- 10 + r <- numeric(n) + for (i in 1:n) { + if (i == 6) x <- 100 + r[i] <- x + i + } + r + } > g() [1] 1 2 3 4 5 106 107 108 109 110 On Fri, 13 Jan 2023 at 23:28, Valentin Petzel <valentin at petzel.at> wrote: > Hello Akshay, > > R is quite inspired by LISP, where this is a common thing. It is not in > fact that {...} returned something, rather any expression evalulates to > some value, and for a compound statement that is the last evaluated > expre...
2023 Jan 10
1
return value of {....}
...euse in another context: > y = x*2 + 2*x -3 > z <- .Last.value/2 > z [1] 10.5 Yes, you could have used "y" ... -----Original Message----- From: R-help <r-help-bounces at r-project.org> On Behalf Of akshay kulkarni Sent: Monday, January 9, 2023 12:06 PM To: Valentin Petzel <valentin at petzel.at> Cc: R help Mailing list <r-help at r-project.org> Subject: Re: [R] return value of {....} Dear Valentin, But why should {....} "return" a value? It could just as well evaluate all the expressions and store the resulting object...
2023 Jan 09
1
return value of {....}
...euse in another context: > y = x*2 + 2*x -3 > z <- .Last.value/2 > z [1] 10.5 Yes, you could have used "y" ... -----Original Message----- From: R-help <r-help-bounces at r-project.org> On Behalf Of akshay kulkarni Sent: Monday, January 9, 2023 12:06 PM To: Valentin Petzel <valentin at petzel.at> Cc: R help Mailing list <r-help at r-project.org> Subject: Re: [R] return value of {....} Dear Valentin, But why should {....} "return" a value? It could just as well evaluate all the expressions and store the resulting object...
2023 Jan 16
2
return value of {....}
...s a parameter as in example above. b <- 100 myNGfunction(y) John ________________________________________ From: R-help <r-help-bounces at r-project.org> on behalf of Sorkin, John <jsorkin at som.umaryland.edu> Sent: Sunday, January 15, 2023 7:40 PM To: Richard O'Keefe; Valentin Petzel Cc: R help Mailing list Subject: Re: [R] return value of {....} Richard, A slight addition to your code shows an important aspect of R, local vs. global variables: x <- 137 f <- function () { a <- x x <- 42 b <- x list(a=a, b=b) } f() print(x) _____...
2023 Jan 16
1
return value of {....}
...a <- x x <- 42 b <- x list(a=a, b=b) } f() print(x) ________________________________________ From: R-help <r-help-bounces at r-project.org> on behalf of Richard O'Keefe <raoknz at gmail.com> Sent: Sunday, January 15, 2023 6:39 PM To: Valentin Petzel Cc: R help Mailing list Subject: Re: [R] return value of {....} I wonder if the real confusino is not R's scope rules? (begin .) is not Lisp, it's Scheme (a major Lisp dialect), and in Scheme, (begin (define x ...) (define y ...) ...) declares variables x and y that are local to the (begin...
2023 Jan 16
1
return value of {....}
...n the tidyverse because they manage to make some changes, for better and often for verse. -----Original Message----- From: R-help <r-help-bounces at r-project.org> On Behalf Of Sorkin, John Sent: Sunday, January 15, 2023 8:08 PM To: Richard O'Keefe <raoknz at gmail.com>; Valentin Petzel <valentin at petzel.at> Cc: R help Mailing list <r-help at r-project.org> Subject: Re: [R] return value of {....} Richard, I sent my prior email too quickly: A slight addition to your code shows an important aspect of R, local vs. global variables: x <- 137 f <- function () {...
2023 Jan 15
2
Removing variables from data frame with a wile card
...hose name starts with "th" newdata2 <- mydata[,-ColumnToDelete] cat("Data frame after droping column whose name is three\n") newdata2 I hope this helps. John ________________________________________ From: R-help <r-help-bounces at r-project.org> on behalf of Valentin Petzel <valentin at petzel.at> Sent: Saturday, January 14, 2023 1:21 PM To: avi.e.gross at gmail.com Cc: 'R-help Mailing List' Subject: Re: [R] Removing variables from data frame with a wile card Hello Avi, while something like d$something <- ... may seem like you're directly modify...
2023 Jan 09
5
return value of {....}
Dear members, I have the following code: > TB <- {x <- 3;y <- 5} > TB [1] 5 It is consistent with the documentation: For {, the result of the last expression evaluated. This has the visibility of the last evaluation. But both x AND y are created, but the "return value" is y. How can this be advantageous for solving practical problems?
2023 Jan 15
0
Removing variables from data frame with a wile card
...n these methods. Many programming languages have some qualms (I mean designers and programmers, and just plain purists) about when "pointers" of sorts are used and whether things should be mutable and so on so I prefer to avoid religious wars. -----Original Message----- From: Valentin Petzel <valentin at petzel.at> Sent: Saturday, January 14, 2023 1:21 PM To: avi.e.gross at gmail.com Cc: 'R-help Mailing List' <r-help at r-project.org> Subject: Re: [R] Removing variables from data frame with a wile card Hello Avi, while something like d$something <- ... may see...
2023 Jan 14
1
Removing variables from data frame with a wile card
Hello Avi, while something like d$something <- ... may seem like you're directly modifying the data it does not actually do so. Most R objects try to be immutable, that is, the object may not change after creation. This guarantees that if you have a binding for same object the object won't change sneakily. There is a data structure that is in fact mutable which are environments. For
2023 Jan 14
3
Removing variables from data frame with a wile card
Steven, Just want to add a few things to what people wrote. In base R, the methods mentioned will let you make a copy of your original DF that is missing the items you are selecting that match your pattern. That is fine. For some purposes, you want to keep the original data.frame and remove a column within it. You can do that in several ways but the simplest is something where you sat the
2005 Jun 01
2
Samba Share Refresh Problem
Hello, I have search up and down about this problem and I have since a lot of posts of people who have had the problem but no solutions so I am posting here hoping that someone can help me out. Here is the scenario. I have Samba Version 3.010 running on Ubuntu 5.04. Everything is working very well with the exception of one item. I have created a shared and when I create a new folder I have