Ryan Perlman

Greenhorn
+ Follow
since Oct 31, 2001
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Ryan Perlman

HOMEWORK hints please :roll: I know there is classes in the API to do this but that is not the assignment. So please don't point me to AffineTransOp(). I will just post snippits since there is alot. I GUI that load an 2 dimesional PixelImage Then I have created 4 transformation with a 2Dimesional weight array. Example

PixelImage Class

Yes I know this is not right I have been fussing with it all night. I don't really understand the concept of the Convolution Operation
the only differences with the other transformation are the weights that are passed in
Any hints would be appreciated
[ April 08, 2002: Message edited by: Ryan Perlman ]
22 years ago
This is for school: so just point me in the right direction.
I have a filter the flips an image horizontaly

But now I am trying to turn this into a method that flips the image Vertically.
Please put me in the right path
Confused

[ April 04, 2002: Message edited by: Ryan Perlman ]
22 years ago
Instead of going:
MyClass ryan = new MyClass();
can you take the Input from a JTextField and Use it for the Object name of MyClass?
If So where should I continue to look, or what other option do I have.
Ryan Perlman
Having fun while I am learning
22 years ago
This use to be homework. I already did the assignment part now I want to try to expand it to make it even more user friendly. I have a basic GUI 4 buttons and a TextArea when the user clicks the button My showinputdialog comes up with a question. whose balance would you like to view. or whose interest would you like to see or calculate or print I am sure you get the picture. My question is I know I have to use and if/else based on what the user puts in. I want to base that if/else on the name the user enters out of the choices I give the Ryan's or Karens. What do I need to use to read that string. Just need a hint in the right direction Thanks.
Ryan Perlman
Still green but getting better Thanks to the Ranch.
22 years ago
Thanks for the hint it tells me I need to read the methods closer. I did it this way and it works.

Thanks Ryan...
22 years ago
I am stuck on how to go about converting the sum of my vector to a string representation. I am stuck on how to construct my toString() Method in my DataSet class?
22 years ago
This is a homework question and I am almost done with it. but I am a little Stuck. This is what we had to do: Develop a class that represents a data set. Use a Vector inside the class to hold the Integers. Provide the folling public methods
addData()
clearData()
count()
sum()
toString()
Create a driver program to test your DataSet class. Use only consol output.
this is what I have done:

22 years ago
I can total my whole array. but now I am trying to do a total for the rows and an total for the columns. I am stuck on how I need to manipulate the code to just print by row and column seperate.

Thanks Ryan.
22 years ago
I thougth I was doing it right but with my output it is not I know I am making just one little mistake. please point me to the right spot..
here the code:

------------------
22 years ago
I am trying to change the arrays size if some condition is not met.
my user will input 20 numbers between 10 and 100 if one is a duplicate of the other don't add it to the array. here is the code I have. It won't add the duplicate number but it sets that array to zero instead I just want to eliminate that
The code

ANY help is appreciated Ryan
------------------

[This message has been edited by Ryan Perlman (edited November 15, 2001).]
22 years ago
Please Disregard I figured out the errors of my way.. Thanks Ryan

I have a button that says print: when pushed i want to print my array:
heres is the error message that I get:
Cannot Resolve Symbol:
Symbol: Variable input Location: class FirstArray
Here is my code:
import java.awt.*;
import java.awt.event.*;
import javax.swing.*;
public class FirstArray extends JApplet
implements ActionListener
{
JLabel label = new JLabel("enter Integers's");
JTextField inputText = new JTextField(10);
JTextArea output = new JTextArea(10,15);
JScrollPane sp = new JScrollPane( output );
JButton print = new JButton("Print Array");
int count = 0;


public void init()
{
Container c = getContentPane();
c.setLayout(new FlowLayout());
c.add(label);
c.add(inputText);
inputText.addActionListener(this);
c.add(sp);
c.add(print);
print.addActionListener(new display());



}

public void actionPerformed(ActionEvent e)
{
int[] input = new int[20];


if ( count < input.length ){
input[count] = Integer.parseInt(inputText.getText());
output.append(Integer.toString(input[count]) + "\n");
inputText.setText("");
showStatus("Please Enter Another Integer");
count++;
}
if( count == input.length){
output.append("Thank You\n" + "Your Done\n\n");
showStatus("Your Done");
inputText.setEditable(false);
}
}
private class display implements ActionListener
{
public void actionPerformed(ActionEvent e)
{
for(int i = 0; i < input.length; i++){
output = output.append(Integer.toString(input[i]));
}
}
}
}

[This message has been edited by Ryan Perlman (edited November 15, 2001).]
22 years ago
I found the Boolean Wrapper Class in the api early, could I throw a couple of more quarters at the jukebox for just a little more hint? Please
Ryan
22 years ago
I think I can write the method but how to pass the methods boolean value back to the textField that requires String.
I know with setText(Integer.toString(55)); we can pass an int to a string but where should I look to pass a boolean
Frustrated Ryan :confused
22 years ago
still dealing with the previous question I have made the coin toss applet but now I need to fill one more field. I need to make a seperate method That will yeild a value of true or false based on the actionPerformed of the coin. I can not figure out how to get this started.
Here is the code I have so far it all works except there is nothing being sent to the flipField (ie.. true or false);

thanks for all the help everyone has provided so far
[This message has been edited by Marilyn deQueiroz (edited November 09, 2001).]
22 years ago
I am writing a coinToss applet. I have got the applet written except I can't figue out how to get my (tails Field) tlsField, and my (heads Field) hdsField to keep a running count as you press the toss button. They keep reseting there values back to the initial value of 1. There is a Flip Field in the code that does nothing yet because I haven't written a method to set the field to true or false yet. should I do it as a boolean or just as a string?
Here is the code


(edited by Cindy to format code)
[This message has been edited by Cindy Glass (edited November 12, 2001).]
22 years ago