[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x

Statistical Packages

118

Solutions

280

Contributors

Statistical packages are software titles, such as JMP and GNU Octave, and programming languages, such as MATLAB, R and SAS, that are used to discover, explore and analyze data and suggest useful conclusions, either to learn something unexpected or to confirm a hypothesis. The field includes the design and analysis of techniques to give approximate but accurate solutions to hard problems in statistics, econometrics, time-series, optimization and 2D- and 3D-visualization. Data analysis has multiple facets and approaches, encompassing diverse techniques under a variety of names, in different business, science, and social science domains.

Share tech news, updates, or what's on your mind.

Sign up to Post

How to simplify this probability expectation, where X Y Z are 3 random variables.

E[ E[X | Y,Z] | Z ]

I don't recall what the comma means in this expression. I started reviewing probability over a year ago , but work keeps getting in the way, and I am not even sure when I learned about a comma in an expectation expression. Before helping me simplify, could you show me an online definition of the comma in an expectation expression. Once I understand the definition, maybe I'll be able to simplify it.

Thanks in advance.
0
Exploring SharePoint 2016
LVL 12
Exploring SharePoint 2016

Explore SharePoint 2016, the web-based, collaborative platform that integrates with Microsoft Office to provide intranets, secure document management, and collaboration so you can develop your online and offline capabilities.

Hi Experts!

I am running into an error when using CPYFRMIMPF and numerics.    When I run the CPYFRMIMPF command I get these errors..  The copy did not complete for reason code 9. When I have the DDS fields all alpha numeric it works.

This is my CPYFRMIMPF code:

0049.00              CPYFRMIMPF FROMSTMF('/ZIP/ZIPFILE.CSV') +              
0050.00                           TOFILE(*CURLIB/&EDTF) MBROPT(*REPLACE) +  
0051.00                           RCDDLM(*LF) STRDLM(*NONE) +              
0052.00                           RMVBLANK(*TRAILING) RPLNULLVAL(*FLDDFT) +
0052.01                           RMVCOLNAM(*YES)                          
 
This is a sample of the data from the ZIPFILE.CSV

zip_code,distance,city,state
15090,99.162,"Wexford","PA"
15084,99.649,"Tarentum","PA"
15006,98.913,"Bairdford","PA"
15015,98.329,"Bradfordwoods","PA"

This is my DDS:

0001.00 0008 A          R ZIPCREC                   TEXT('ZIP RADIUS')
0002.00 0000 A            ZIP              5A         COLHDG('ZIP CODE')
0003.00 0000 A            ZDIST          4P 3     COLHDG('DISTANCE')
0004.00 0000 A            ZCITY        30A         COLHDG('CITY')    
0005.00 0000 A            ZSTATE       4A         COLHDG('STATE')  

Thanks for your help!!
0
I am trying to figure out what is causing my laptop to freeze at random points during the day.  It seems to happen more often when I am connected to external monitor via HDMI, but cant pinpoint what is actually causing it.  What happens is no .exe will process and it "freezes" exes from starting for 15-60 seconds then all of a sudden it "wakes up" and runs all the queued .exe files.  
So when I realize its stopped allowing new things ill hit windows r (i DO get the run box) and type cmd and hit enter...run box goes away but cmd wont launch for 15-60 seconds and then boom everything ive done in those 15-60 seconds happens in an instant (command prompt box opens, calculator opens, changing tabs in chrome  etc).  Then everything is fine and works for another hour or more (random when it does/doesnt happen).  I CAN alt/tab and change between windows, but if I try to do anything in that window it wont work (until it wakes up and does all the stored tasks), I CANT ctrl-alt-del, its another exe that gets "put in queue" and again,  it will pop up along with my command prompt etc.
I have ran memory checks, sfc, cclean, mbam - running on an SSD for primary OS - no errors that I can tell.
I did just install process explorer but not sure how to pinpoint the "queue"...once everything is in "freeze mode" what do I look for on process explorer?
0
hi, i can get postman to POST to create a VM but using pycharm encountered this error.

code 1: obtain a token
==========================================================================
import requests
url = "https://IP/silvan/apigateway/v1.0/"
get_apis = "apis_include_throttles"

##API URLs
get_token_url = "https://iam-apigateway-proxy.domain.com/v3/auth/tokens"

create_volume_url = "https://evs.sitc-1.domain.com/v2/6d321dd88c7143ba8d6daf3e15f14be9/volumes"
delete_volume_url = "https://evs.stic-1.domain.com/v2/6d321dd88c7143ba8d6daf3e15f14be9/volumes/"
create_vm_url = "https://ecs.sitc-1.domain.com/v2/6d321dd88c7143ba8d6daf3e15f14be9/servers"



##Images Dictionary
images = {
    "Ubuntu 18.10": "5313ace4-4573-404b-abc6-8548ed14c4f7",
    "RHEL7.5-40G": "aa9d05f3-cb90-4776-9c02-617a9906b271",
    "WindowsServer2016WithGUI": "c54d05fa-5ad8-425e-be56-e60ede395230",
    "Windows10Pro": "29caef55-0617-4813-8a17-cb0bef19de16",
    "RHEL7.5": "c5ccd8a7-d8f3-4a4c-91c3-9d93303aee58",
    "Ubuntu16.04LTS": "3f8948fd-c108-48db-9951-1d617e8e5b03",
    "image-kvm-euler": "298e2912-5a7a-4178-8ac4-b260712d514c",
    "image-ManageOne": "80d9b0ee-a5b3-42fe-99ed-fc32c57da5b3",
    "esight_image": "e1e94234-f3e7-4793-8bdb-0cef9e3194cf"
}


def get_token():
    body = {
        "auth": {
            "identity": {
                "methods": [
                    "password"
                ],
                "password": {
                    "user": {
    …
0
hi,

why can't delete my system volumes with error. checked has no more VM, snaps, etc.

use postman to delete with error. ps check my postman.
2.jpg
use python script to delete with error. ps check my python code

import requests

get_token_url = "https://iam-apigateway-proxy.domain.com/v3/auth/tokens"

body = {
    "auth": {
        "identity": {
            "methods": [
                "password"
            ],
            "password": {
                "user": {
                    "domain": {
                        "name": "XXXXX"
                    },
                    "name": "XXXXX",
                    "password": "XXXXX"
                }
            }
        },
        "scope": {
            "project": {
                "id": "cd088007d3b84e7fa894478e6fe667c4",
                "domain": {
                    "name": "XXXXX"
                }
            }
        }
    }
}

# POST to the API
results = requests.post(get_token_url, json=body, verify=False)


token = results.headers['X-Subject-Token']

#Deletion

volume_id = [
    'c3b803ee-f1ab-428d-bc55-01b380c36d49',
    '065ba0b3-959a-4dc0-af23-17b8a1099367',
    'b282ea13-5e24-48fb-b7e2-84fce0973621',
    'aa87fc71-ae1b-47ee-82fc-bcd73a59538d',
    'a72cc934-473e-4cde-8eb0-743ca058e350'

]

delete_url = "https://evs.domain.com/v2/cd088007d3b84e7fa894478e6fe667c4/volumes/"
headers = {
    'content-type': "application/json",
    …
0
Hi,

I'm currently working in AWS and trying to use a Lambda function to automate the creation of my AMIs. I'm doing this via the use of the Python script below, but when I test it it returns an error. Can anyone shed any light on what I should be looking at please?

Script:

import boto3
import collections
import datetime
import sys
import pprint

ec = boto3.client('ec2')
#image = ec.Image('id')

def lambda_handler(event, context):
   
    reservations = ec.describe_instances(
        Filters=[
            {'Name': 'tag-key', 'Values': ['backup', 'Backup']},
        ]
    ).get(
        'Reservations', []
    )

    instances = sum(
        [
            [i for i in r['Instances']]
            for r in reservations
        ], [])

    print "Found %d instances that need backing up" % len(instances)

    to_tag = collections.defaultdict(list)

for instance in instances:
    try:
        retention_days = [
            int(t.get('Value')) for t in instance['Tags']
            if t['Key'] == 'Retention'][0]
    except IndexError:
        retention_days = 7

    finally:

        #for dev in instance['BlockDeviceMappings']:
        #    if dev.get('Ebs', None) is None:
        #        continue
        #    vol_id = dev['Ebs']['VolumeId']
        #    print "Found EBS volume %s on instance %s" % (
        #        vol_id, instance['InstanceId'])

            #snap = ec.create_snapshot(
            #    VolumeId=vol_id,
      …
0
How to calculate linear regression in oracle plsql.
Please see the file attached.
C--Tanuja-Lake_IL-BRDs-linear-regre.docx
0
How to copy and paste data with conditional formatting format from minitab worksheet into excel ?
I tried but they copy in values and the format that i had in minitab was not reflected in excel.
0
How do i get the attached data "normalised" -- made into normal distribution ?

Worksheet "Data" = Full Data
"Filtered 25-65" = data with 25-65 s filtered by "Data" and copied in this worksheet.

If i use 25-65, it has the best result - ie, less skewness but stil not into normal distribution.

Any idea to use that range such that the data plotted is normal distribution  ?
Data-25-65--Check-Normal--EE.xlsx
0
Hi,
I would like to prepare data for regression analysis.
I can prepare data in two forms.
a) values
b) rankings.
example:
values  60,30,25,90
rankings 2,3,4,1
Which format would be most suitable or does it not matter ?
many thanks
Ian
0
OWASP: Avoiding Hacker Tricks
LVL 12
OWASP: Avoiding Hacker Tricks

Learn to build secure applications from the mindset of the hacker and avoid being exploited.

How is
model <- lm(
           formula = Petal.Width ~ Petal.Length,
            data = iris
            )
different from
model <- lm(
            formula = iris$Petal.Width ~ iris$Petal.Length,
            data = iris
            )

The output of both the commands are same but my prediction output differs.
NOTE: I had assumed Petal.Width is same as iris$Petal.Width, clearly they are not. I don't understand how are they different.
Attached RScript contains complete code
0
Hello,

I have  a list of lists.  The lists in the list of lists are file names.  I use lapply to read and merge the contents of each list in the list of lists (3 merged contents in this case  which will be the content of 3 files).  Then, I  have to change the name of the 3 resulting files and finally I have to write the contents of the files to each file.

 lc <- list("test.txt", "test.txt", "test.txt", "test.txt")
 lc1 <- list("test.txt", "test.txt", "test.txt")
 lc2 <- list("test.txt", "test.txt")
#list of lists.  The lists contain file names
 lc <- list(lc, lc1, lc2)
#new names for the three lists in the list of lists
 new_dataFns <- list("name1", "name2", "name3")
 file_paths <- NULL
 new_path <- NULL
#add the file names to the path and read and merge the contents of each list in the list of lists
 lapply(
    lc,
    function(lc) {
     filenames <- file.path(dataFnsDir, lc)
     dataList= lapply(filenames, function (x) read.table(file=x, header=TRUE))
     Reduce(function(x,y) merge(x,y), dataList)
     #   print(dataList)

    }
  )  

#add the new name of the file to the path total will be 3 paths/fille_newname.tsv.  
 lapply(new_path, function(new_path){new_path <- file.path(getwd(), new_dataFns)

The statements above work because lc and  new_dataFns are global and I can pass them to the lapply function

#Finally, I need to write the merged contents to the corresponding file (path/name.tsv).  I tried the following statement, but this …
0
I would like to change the node names of my data.tree object (tjpCPI) from IDs to readable tags. A sample of the tree structure is here:
> print(tjpCPI, "CPI.Tag")
                                levelName                          CPI.Tag
1   378257447                                                          CPI
2    ¦--378257497                                                     Food
3    ¦   ¦--378259447                                              Cereals
4    ¦   ¦   ¦--378259457                                             Rice
5    ¦   ¦   ¦   ¦--378259467                                Non Glutinous
6    ¦   ¦   ¦   ¦   ¦--378259477                                   Rice-A
7    ¦   ¦   ¦   ¦   °--378259487                                   Rice-B
8    ¦   ¦   ¦   °--378259497                                    Glutinous
9    ¦   ¦   ¦--378259507                                            Bread
10   ¦   ¦   ¦   ¦--378259517                                  White Bread
11   ¦   ¦   ¦   ¦--378259527                                Bean Jam Buns
12   ¦   ¦   ¦   °--378259537                                   Curry Buns
13   ¦   ¦   ¦--378259547                                          Noodles

I would like levelName to become CPI.Tag.

How might I do that without needing to iterate through each node?
0
I would like to change the names of the members of the list. The list is of a CPI hierarchy - the trouble is the names are now ID numbers, that are difficult to interpret. Each one of the members has a readable tag, that is "CPI.Tag".

How would I swap the label that is used for the name  currently to the "CPI.Tag"? (the display of a few sample members is attached)
2018-08-14_13-32-00.png

I thought it would be something along the lines of names(jpCPIlist)<-jpCPIlist$CPI.Tag, but evidently not..
0
How to remove any character from a string if it is not part of the below "x character set" .
Remove a character from a given string -if it is not part of the below x character set.
X character set: After removing the character there should not be any space on the character that gets removed.
---------------------
a b c d e f g h I j k l m n o p q r s t u v w x y z
A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
0 1 2 3 4 5 6 7 8 9
/ - ? : ( ) . , ‘ +

Example
     '020?Dome@&++;stic CT out;%going?20测试叙事测试叙事@@@@test'
Expected output is
    020?Dome++stic CT outgoing?20test


I am using the below query but it is replacing '+'. I don't want to replace this + because it a part of x character set.

select translate(REGEXP_REPLACE ('020?Dome@&++;stic CT out;%going?20测试叙事测试叙事@@@@test','[^' || CHR(32) ||'-' ||CHR (127) || ']', ''),'+=!“%&*<>;{@#_',' ') AS TEST from dual;
0
Hi
I have one PDC server 2008R2 (D2R03Q02)  holding all FSMO roles and a second PDC server 2012R2 (PowerT130) who is not replicating any more since more than a month.

on PDC1 the command repadmin /showrepl shows no erros
on PDC2 the command repadmin /showrepl contains several errors

the netdom query FSMO shows all roles on PDC D2R03Q02

Connectivity: I can ping both servers

If I try to transfer FSMO to the second PDC PowerT130 I get the  ERROR The current Operations master is offline. The role cannot be transferred.
But the PDC D2R03Q02 is up and running and I can ping it from the second PDC.

Dcdiag show many errors and warnings on both PDC

Errors related to Ldap for example

or warnings like :

Warning: DcGetDcName(PDC_REQUIRED) call failed, error 1355

Warning: DcGetDcName(TIME_SERVER) call failed, error 1355
A Time Server could not be located.
The server holding the PDC role is down.
Warning: DcGetDcName(GOOD_TIME_SERVER_PREFERRED) call failed,
error 1355
A Good Time Server could not be located.

I attached The complet Dcdiag report dcdia.txt


DNSLINT command look good

DNSLint Report

System Date: Fri Jul 20 23:42:26 2018

Command run:

dnslint /ad 192.168.1.6 /s 192.168.1.7 /v

 Root of Active Directory Forest:

    Ecole.Schulz.Local
Active Directory Forest Replication GUIDs Found:
 
DC: D2R03Q02
GUID: 1a3677e0-7a77-413b-b70d-f0ede03ff7af

DC: POWERT130
GUID: …
0
The process of ML is comparable to data processing. Both systems search through information to appear for patterns. However, rather than extracting information for human comprehension as just in case of knowledge mining, ML uses that information to discover trends in data and alter program actions.
0
All, I am preparing for MFE (financial engineering). I could not thin of any other forum where i could seek help for clearing my doubts on financial products.

Dear experts, is my below understanding correct?

Is  r>-1  coming from this statement?

&&&1 + r&&&

if 1+r>0, then r>-1
*****

Extract from Stochastic Calculus for Finance 1

We introduce also an interest rate 1^n. One dollar invested in the money

market at time zero will yield 1 + r dollars at time one. Conversely, one dollar

borrowed from the money market at time zero will result in a debt of &&&1 + r&&&

at time one. In particular, the interest rate for borrowing is the same as the

interest rate for investing. It is almost always true that r >= 0, and this is

the case to keep in mind. However, the mathematics we develop requires only

that r > -1.

Kindly guide
0
I need to execute a substring function on each row of a single column dataframe in R Studio, then assign that value to a new dataframe.
0
Starting with Angular 5
LVL 12
Starting with Angular 5

Learn the essential features and functions of the popular JavaScript framework for building mobile, desktop and web applications.

hi,

Anyone know how to scale out R server/service in MS SQL 2016 and later?
0
Trying to run

        Dim RetVal As Long
        RetVal = Shell("for %%i in (C D E F G H I J K L M N O P Q R S T U V W X Y Z) DO @if exist %%i: dir %%i:\*.* /s /b >E:\zzz\Zip-Bak\DayBkUp\DirectoryListHistory\%%i.txt")



Get error run time error 53 file not found?

It runs fine in a dos batch file

Trying to create a series of text files with a list of all files on each drive on my computer

Thanks
DIR-ALL-Drives.txt
0
Enabling R commands on T-SQL of MS SQL Server
I have installed Microsoft SQL server 2017 and SQL server management studio on my laptop computer with windows 10 Professional.  I am able to connect to the database from management studio.  I have also installed R (version 3.5.0 (The R foundation for Statistical Computing).
I learnt that from SQL server 2016 onwards, MS SQL server permits R commands on T-SQL.
I am familiar with both T-SQL and R commands.
I want to know how to enable execution of R commands on T-SQL.
0
Hello,
I'm trying to pass a value to a List, but I get an error Cannot implicitly convert System.Collections.Generic.List<char> to System.Collections.Generic.List<string>.
So, here's my code...
public List<string> NomeContrato { get; set; }

Open in new window


BindingSource bs = new BindingSource();
            bs.DataSource = LoadContratos();
            var editForm = new Concelhos_Edit();
            var editFormModel = new Info();
            editFormModel.Id = concelhos_datagrid.CurrentRow.Cells[0].Value.ToString();
            var _nomeContrato = contratosdt.AsEnumerable().FirstOrDefault(a => a.Field<int>("IdContrato") == ((DataRowView)bs.Current).Row.Field<int>("IdContrato")).Field<string>("Designacao");
            editFormModel.NomeContrato = _nomeContrato.ToList(); //--> Here's where the code breaks and get Error!

Open in new window


Changing this
public List<string> NomeContrato { get; set; }

Open in new window

to this
public List<char> NomeContrato { get; set; }

Open in new window

, I get my Combobox with one letter per line, like this...
W
o
r
l
d

Any help?
Thanks.
0
I would like to perform fractal analysis on a financial series (stock exchange index). What shall I use (prices or log returns) for calculating fractal dimension, Hurst Exponent, for performing R/S Analysis and for predictions? Are there R functions that calculate all of these immediately? Are there any things I need to take care of when analyzing the index? Thank you in advance!
0
First of all I am doing a program kinda simple long program, here is the full details:

The P-v-T relation for real gases can take many forms. The simplest relations are the ideal gas equation and the Van der Waals equation. These relations are to be applied to superheated steam. The file “pvt.txt” contains the P-v-T data of superheated steam (10 – 800 kPa) for the temperature range of 200 oC through 1200 oC, obtained from the steam tables.

Write a C program to read the steam table data “pvt.txt”. In the C program, estimate the density of steam for the pressure range 10 through 800 kPa, and temperature range 200 oC through 1200 oC,

(1) Using the ideal-gas relation: m3/kg where R = 0.4615 kJ/kgK, T is temperature [K] and P is pressure [kPa].

(2) Using the Van der Waals equation:

where R = 0.4615 kJ/kgK, T is temperature [K] and P is pressure [kPa]. The constants are obtained from and where Pcr = 22060 kPa and Tcr = 647.1 K.

In each case, calculate the resulting percentage error of the estimated density as follows: Error = x 100% Submit a report which must include: 1. Introduction, algorithm or flowchart, the C program, and the density from steam table. 2. The estimated density table when using the ideal gas equation. 3. The percentage error table when using the ideal gas equation. 4. The estimated density table when using the Van der Waals equation. 5. The percentage error table when using the Van der Waals equation. 6. Discussion and conclusion. Note: Density…
0

Statistical Packages

118

Solutions

280

Contributors

Statistical packages are software titles, such as JMP and GNU Octave, and programming languages, such as MATLAB, R and SAS, that are used to discover, explore and analyze data and suggest useful conclusions, either to learn something unexpected or to confirm a hypothesis. The field includes the design and analysis of techniques to give approximate but accurate solutions to hard problems in statistics, econometrics, time-series, optimization and 2D- and 3D-visualization. Data analysis has multiple facets and approaches, encompassing diverse techniques under a variety of names, in different business, science, and social science domains.

Top Experts In
Statistical Packages
<
Monthly
>