Skip to content
This repository has been archived by the owner on Sep 27, 2023. It is now read-only.

no method for coercing this S4 class to a vector #85

Open
huahang opened this issue Jun 24, 2016 · 14 comments
Open

no method for coercing this S4 class to a vector #85

huahang opened this issue Jun 24, 2016 · 14 comments
Assignees

Comments

@huahang
Copy link
Contributor

huahang commented Jun 24, 2016

Hi,

I get the following error when I try to run demo.sh. What's wrong here?

Thanks,
Huahang

_____ 1.330 Parsing _tmp/cpp/demo3/case_map.csv
Error in as.vector(data) : 
  no method for coercing this S4 class to a vector
Calls: main ... as.matrix -> as.matrix.default -> array -> as.vector
@huahang
Copy link
Contributor Author

huahang commented Jun 27, 2016

I have done a little bit debugging. It seems the line of code that causes this error is:

https://github.com/google/rappor/blob/master/analysis/R/alternative.R#L79

And the call stack is:

ConstrainedLinModel alternative.R
FitDistribution decode.R
Decode decode.R
RunRappor tests/compare_dist.R

I'm new to R. I hope this information would be useful.

@ananthr ananthr self-assigned this Jun 29, 2016
@ananthr
Copy link
Contributor

ananthr commented Jun 29, 2016

Thanks huahang; we're a little busy at the moment but we'll get back to this as soon as possible.

@wjz0811
Copy link

wjz0811 commented Jun 12, 2017

Hi ananthr,

A fan of the RAPPOR algorithm, I wonder if there has been a solution for this error yet?

Thanks a lot,
Jinzhao

@OLDFE
Copy link

OLDFE commented Dec 4, 2017

Is this problem fixed yet?I'm in trouble too

@jerryhive
Copy link

Just downloaded the RAPPOR, got the same issue.
coefs <- do.call(lsei, model)$X caused the issue

ConstrainedLinModel <- function(X,Y) {
model <- MakeLseiModel(X, Y$estimates, Y$stds)
coefs <- do.call(lsei, model)$X
names(coefs) <- colnames(X)
coefs
}

Any solution?

@Enjoyeer
Copy link

As mentioned above,I got error message"no method for coercing this S4 class to a vector" when try to run demo.sh

@shuailishasls
Copy link

As mentioned above,I got error message"no method for coercing this S4 class to a vector" when try to run demo.sh

R package is installed according to setup.sh, I succeeded

@Enjoyeer
Copy link

Enjoyeer commented Dec 4, 2018

As mentioned above,I got error message"no method for coercing this S4 class to a vector" when try to run demo.sh

R package is installed according to setup.sh, I succeeded

thanks shuailishasls
I try to install R according to setup.sh. But it seems the default version is 3.0.2,and ggplot2 package is incompatible with R 3.0.2. I have spent 2 days on it.

@shuailishasls
Copy link

As mentioned above,I got error message"no method for coercing this S4 class to a vector" when try to run demo.sh

R package is installed according to setup.sh, I succeeded

thanks shuailishasls
I try to install R according to setup.sh. But it seems the default version is 3.0.2,and ggplot2 package is incompatible with R 3.0.2. I have spent 2 days on it.

U can install the package before 2015,such as ggplot2_1.0.0.tar.gz.

@Enjoyeer
Copy link

Enjoyeer commented Dec 5, 2018

As mentioned above,I got error message"no method for coercing this S4 class to a vector" when try to run demo.sh

R package is installed according to setup.sh, I succeeded

thanks shuailishasls
I try to install R according to setup.sh. But it seems the default version is 3.0.2,and ggplot2 package is incompatible with R 3.0.2. I have spent 2 days on it.

U can install the package before 2015,such as ggplot2_1.0.0.tar.gz.

thanks a lot!
Follow your suggestion,I installed almost a dozen packages before 2015,Thank goodness,it worked!.

@rbhk1
Copy link

rbhk1 commented Feb 27, 2019

Hello,
Has this problem been solved?
Thanks

@lilyhhha
Copy link

As mentioned above,I got error message"no method for coercing this S4 class to a vector" when try to run demo.sh

R package is installed according to setup.sh, I succeeded

thanks shuailishasls
I try to install R according to setup.sh. But it seems the default version is 3.0.2,and ggplot2 package is incompatible with R 3.0.2. I have spent 2 days on it.

U can install the package before 2015,such as ggplot2_1.0.0.tar.gz.

hello ,can you help me to revolve this problem?It appearances when I run ./demo.sh. Hope your reply,thanks.

~/rappor-master/rappor-master/client/cpp ~/rappor-master/rappor-masterg++ -Wall -Wextra -I_tmp/ -c -o _tmp/openssl_hash_impl.o openssl_hash_impl.cc openssl_hash_impl.cc:20:10: fatal error: openssl/evp.h: No such file or directory#include <openssl/evp.h> // EVP_sha256compilation terminated.Makefile:75: recipe for target '_tmp/openssl_hash_impl.o' failed make: *** [_tmp/openssl_hash_impl.o] Error 1

@lilyhhha
Copy link

我已经做了一些调试。似乎导致此错误的代码行是:

https://github.com/google/rappor/blob/master/analysis/R/alternative.R#L79

调用堆栈是:

ConstrainedLinModel alternative.R
FitDistribution decode.R
Decode decode.R
RunRappor tests/compare_dist.R

我是R的新手。我希望这些信息会有所帮助。

Hello, have you solved the problem at that time? Could you please help me? I run these files all reported errors../buid.sh and ./demo.sh

@lilyhhha
Copy link

Hi,

I get the following error when I try to run demo.sh. What's wrong here?

Thanks, Huahang

_____ 1.330 Parsing _tmp/cpp/demo3/case_map.csv
Error in as.vector(data) : 
  no method for coercing this S4 class to a vector
Calls: main ... as.matrix -> as.matrix.default -> array -> as.vector

Hello, have you solved the problem back there? I hope I can contact you and teach me for a fee. Thank you. I'm installing.sh and these are getting a lot of errors.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants