Displaying 20 results from an estimated 104 matches for "mtx".
Did you mean:
max
2012 Jan 30
1
Quantum scalar i40 tape partitions
...: 00 Id: 00 Lun: 00
Vendor: HP Model: Ultrium 5-SCSI Rev: Z58Z
Type: Sequential-Access ANSI SCSI revision: 06
Host: scsi0 Channel: 00 Id: 00 Lun: 01
Vendor: QUANTUM Model: Scalar i40-i80 Rev: 135G
Type: Medium Changer ANSI SCSI revision: 03
# mtx -f /dev/sg0 inquiry
mtx: Request Sense: Long Report=yes
mtx: Request Sense: Valid Residual=no
mtx: Request Sense: Error Code=70 (Current)
mtx: Request Sense: Sense Key=Illegal Request
mtx: Request Sense: FileMark=no
mtx: Request Sense: EOM=no
mtx: Request Sense: ILI=no
mtx: Request Sense: Additiona...
2004 Nov 25
4
Avoiding for-loops
...of the matrix in a vector. I tried to do the
job by using two for-loops but it doens't seem to be a
clever way, and I'd like to know a more efficient code
for a large matrix of thousands of rows and columns.
Below is my code for your reference.
Thanks a lot.
John
####################
# mtx.sym is a symmetric matrix
> my.ftn <- function(size_mtx, mtx) {
+ my.vector <- c()
+ for ( i in 1:size_mtx ) {
+ cat(".")
+ for ( j in 1:size_mtx ) {
+ if ( upper.tri(mtx)[i,j] ) {
+ my.vector <- c(my.vector, mtx[i,j])
+ }}}
+ cat("\n")
+ }
>
# if I have a matrix...
2005 Feb 23
1
H-F corr.: covariance matrix for interaction effect
...) / ((k-1) * ((n-1) - (k-1)*epsiGG))
c(epsiGG,epsiHF)
}
# three factors, facROI,facCond,facSubj
# facROI,facCond are main effects, facSubj is "repeatedness"
# G-G and H-F corrections for a main effect
# we do the gghf stuff for the ROI, which means ROIs in columns,
# subjects in rows
mtx <- NULL
for (iROI in 1:length(unique( facROI ))) {
for (iSubj in 1:length(unique( facSubj ))) {
mtx <- c(mtx,
mean(vecData[facROI==unique(facROI)[iROI] &
facSubj==unique(facSubj)[iSubj]])
)
}
}
mtx <- matrix(mtx,ncol=length(unique( facROI )),byro...
2005 Feb 23
1
H-F corr.: covariance matrix for interaction effect
...) / ((k-1) * ((n-1) - (k-1)*epsiGG))
c(epsiGG,epsiHF)
}
# three factors, facROI,facCond,facSubj
# facROI,facCond are main effects, facSubj is "repeatedness"
# G-G and H-F corrections for a main effect
# we do the gghf stuff for the ROI, which means ROIs in columns,
# subjects in rows
mtx <- NULL
for (iROI in 1:length(unique( facROI ))) {
for (iSubj in 1:length(unique( facSubj ))) {
mtx <- c(mtx,
mean(vecData[facROI==unique(facROI)[iROI] &
facSubj==unique(facSubj)[iSubj]])
)
}
}
mtx <- matrix(mtx,ncol=length(unique( facROI )),byro...
2005 May 19
14
R annoyances
...eat ways to deal with them.
(a) When using "apply" row-wise to a matrix, it returns
the results column-wise, and to preserve the original
orientation, I've to do a transpose. E.g. I've to keep
doing a transpose, which I consider to be quite annoying.
transformed.mtx <- t(apply( mtx, 1, exp))
(b) When extracting 2 or more columns of a matrix,
R returns the result as a matrix, BUT when extracting
just one column, it returns a vector/array, rather than
a matrix, so I've to keep doing as.matrix, which is annoying.
sub.mtx <- as.matrix(mtx...
2010 Apr 23
2
Matrix diagonal help
Hi
Suppose I have a matrix (cohort are rows and years are columns)
[2000] [2001] [2002] [2003]
[C1] 0.01 0.03 0.02 0.09
[C2] 0.06 0.05 0.07 0.11
[C3] 0.1 0.5 0.4 0.98
[C4] 0.7 0.6 0.2 0.77
I want to extracts the diagonals to get a matrix which looks like this (C1
becomes C2 in 2002, C2 becomes C3 in 2003
2010 Nov 07
1
How do I order xyplot line points?
...e blue "bedGz" category.
What I would like is that categorical points are joined by lines in lexicographic order, to match ordering of labels on the x-axis.
How do I modify the xyplot command so that the lines are joined in correct order?
Here is the code I am using to draw my xyplot:
mtx <- read.table(mtxf.in, as.is=F, sep="\t", quote='', header=T, stringsAsFactors=T)
attach(mtx)...
2008 Mar 13
3
Overland Arcvault 12 and sequential/random settings
My unit's firmware: library 05.03, tape d22h, shows the device as set to
random mode. But mtx -f /dev/st0 status gives an error that google says
the device is in sequential mode. dmesg|grep -i hp does reflect CentOS
thinks the device is a sequential unit.
I've tried this with Fedora 8, too, and both show the same, so it is
either an issue with CentOS/Fedora RPMs, or the version of...
2004 Nov 02
3
n-th power of a matrix
Hello all,
To calculate the power of a matrix, I used the command "mtx.exp(X, n)", but
there is an error saying "Error: couldn't find function "mtx.exp"". How can
I deal with this problem?
Jing
2007 Nov 16
1
Efficient way to compute power of a sparse matrix
Dear all,
I would like to compute power of a square non symmetric matrix. This is
a part of a simulation study. Matrices are quite large (e.g., 900 by
900), and contains many 0 (more than 99 %). I have try the function
mtx.exp of the Biodem package:
library(Biodem)
m <- matrix(0, 900, 900)
i <- sample(1:900, 3000, replace = T)
j <- sample(1:900, 3000, replace = T)
for(x in 1:3000)
m[i[x],j[x]] <- runif(1)
system.time(mtx.exp(m, 20))
This returns (sorry, in french):
utilisateur syst?me ?c...
2008 May 14
6
PWGL in wine, problems
Hello,
I'm new on this list. First of all, thank you to all the developers of this
great project!
At the moment there is only an application that keeps me on both macos and
windows, its name is PWGL a free environment for computer assisted
composition in openGL. (http://www2.siba.fi/PWGL/)
I'm running Ubuntu 8.04 and wine 0.9.59.
I have to say that I also installed vcrun2005 and
2012 May 15
0
How to apply a function to a multidimensional array, based on its indices
...e a data.frame or matrix that has the indices"
Actually, it must be a matrix, indices can't be of type list.
A way to avoid loops/apply altogether, and much faster, is the one
creating K3
(K is the result from the op.)
n <- 20
t2 <- system.time({
K2 <- array(0,dim=c(n,n,n,n))
mtx <- data.matrix( expand.grid(x1=1:n,x2=1:n,y1=1:n,y2=1:n) )
K2[mtx] <- apply(mtx, 1, function(x) x["x1"]*x["y2"] -
sin(x['x2']*x['y1']) )
})
t3 <- system.time({
K3 <- array(0,dim=c(n,n,n,n))
mtx <- data.matrix( expand.grid(x1=1:n,x2=1:n,y1=1:n,y2=...
2005 Aug 17
2
power of a matrix
Dear all,
I have a population with three age-classes, at time t=0 the population
is:
n.zero <- c(1,0,0)
I have a transition matrix A which denotes "fertility" and "survival":
A <- matrix(c(0,1,5, 0.3,0,0, 0,0.5,0), ncol=3, byrow=TRUE)
To obtain the population at t=1, I calculate:
A %*% n.zero
To obtain the population t=2, I calculate:
A %*% (A %*% n.zero)
... and so
2010 Nov 29
1
selecting only corresponding categories from a confusion matrix
Dear R colleagues,
as a result of my calculations regarding the inter-observer-variability
in bronchoscopy, I get a confusion matrix like the following:
0 1 1001 1010 11
0 609 11 54 36 6
1 1 2 6 0 2
10 14 0 0 8 4
100 4 0 0 0 0
1000 23 7 12 10 5
1001 0 0 4 0 0
1010 4 0 0 3 0
1011 1 0 1 0 2
11
2005 Feb 18
1
Two-factorial Huynh-Feldt-Test
...out it.
I've tried to do it in several ways, but this is the only one that gives
a somewhat reasonable result.
Can anyone give me a suggestion of how I could do this, where I could
find information about it etc? Google doesn't help much except more SAS
examples...:-(
hf <- function(mtxCov,ncol,nrow) {
X <- mtxCov*(nrow-1)
r <- length(X[,1])
D <- 0
for (i in 1: r) D<- D+ X[i,i]
D <- D/r
SPm <- mean(X)
SPm2 <- sum(X^2)
SSrm <- 0
for (i in 1: r) SSrm<- SSrm + mean(X[i,])^2
epsilon <- (ncol^2*(D-SPm)^2) / ((ncol-1) * (SPm2 - 2*ncol*S...
2010 Aug 02
1
Multibyte characters in (row) names
I have an array with names which contain multibyte characters. ?When I try to
write the array to a file using write.table and row.names = T I receive an error
message when the first such name is encountered, saying that I have not
specified the option to generate NA instead. ?I really would be satisfied if the
row name in the file were exactly what is displayed when I print the array on
the
2004 Jan 22
1
Re: matrix exponential: M0
...ll!
First of all, I'd like to apologize for my poor English. It's for years
I don't use it.
This is a R-version of a function I wrote a long ago for my HP48 calculator.
It works with the binary expression of the power and just need to
duplicate the mem used by X.
Hope this helps.
mtx.exp<-function(X,n)
#Function to calculate the n-th power of a matrix X;
{
phi <- diag(rep(1,length(X[1,])))
pot <- X #This is the first power of the matrix.
while (n > 0)
{
if (n%%2)
{
phi <- phi%*%pot;
}
n <- n%/%2;
pot <- pot %*% pot;
}
return(phi);...
2013 Jun 14
1
IMAP MOVE and lazy_expunge_only_last_instance
Hello!
im testing lazy_expunge_only_last_instance here and it seems it works wrong
with IMAP MOVE
IN:
14 uid move 13 "INBOX"
OUT:
* OK [COPYUID 1188569061 13 34] Moved UIDs.
* 5 EXPUNGE
14 OK Move completed.
dovecot.log:
2013-06-14 10:56:06 imap(test13 at mtx.ru): Info: copy from Test: box=INBOX,
uid=34, msgid=<1294858169.32435.3.camel at int.office.matrix>, size=996,
from=Pavel Volkovitskiy <int at mtx.ru>, subject=test, flags=(\Seen)
2013-06-14 10:56:06 imap(test13 at mtx.ru): Info: copy from Test:
box=.EXPUNGED/Test, uid=9, msgid=<1294...
2011 Aug 16
1
how to sort the levels of a table
...via the
following code:
## observations of the reference
obsValues<-factor(unlist(input[,-c(1,ncol(input))]))
## observations of the observers
refValues<-factor(input[,ncol(input)])
## data.frame that relates observations of observers and reference
RefObs<-data.frame(refValues, obsValues)
mtx<-table(
RefObs$obsValues,
RefObs$refValues,
dnn=c("observers", "reference"),
useNA=c("always")
)
And now the problem:
I need to sort the levels/classes of the table. Both axes shall be
ordered 1st according to...
2011 Jan 26
0
Fwd: MAtrix addressing
...l has
>> the appropriate values of that area.
>>
>> A+B => Combine these two and have a function that returns the
>> appropriate value of a subarea given its coords. Attention my area
>> spans from -1 to 1 in y plane and from -1 to 1 in the x plane.
>
> mtx <- matrix(seq(1:36), nrow=6, byrow=TRUE,
dimnames=list(x=seq(-1, 1, length=7)[-7], y=seq(-1, 1, length=7)[-7]) )
> mtx
y
x -1 -0.666666666666667 -0.333333333333333 0
0.333333333333333 0.666666666666667
-1 1 2...